I’m trying to use rpa.archive to zip a folder containing pdfs, but i’m only getting PermissionError: [Errno 13] Permission denied: Help would be greatly appreciated!
experimenting with zipping different folders (this one is located at c:/users etc, so i tried to create a c:/test in which i granted it all permissions - still didn’t work!
tried to use both Add To Archive ${FILES_TO_ARCHIVE} ${archive_name} and Archive Folder With Zip ${folder_name} ${archive_name}
turning off antivirus protection
designating the entire path C:${/}Users${/}adada${/}Robocorp${/}Certification${/}my-certii-robot${/}temp${/}order${/} instead of ${OUTPUT_DIR}${/}temp${/}order${/}order
checking that any of the files to be zipped are in use (they aren’t)
0.5s sleep between functions
check for valid file paths
recreate the issue in the interactive window. Spoiler: It occurred there as well
And there is no errors during environment building? And if you download that portal example and run it it only gets permission error? Would it be possible to share more of the error output from terminal?
Thanks a lot for the input, you helped me back on the right path.
Interestingly, when I started a new project in which I tried to use the RPA.Archive library, it threw an environment error about Conda which my original project didn’t show. It turned out that I was using the wrong terminal in VS Code, so I switched to the cmd one to make a base conda environment on recommendation from stackoverflow. This fixed the issue!
That permission error basically means some process is holding a file open, so I do not think this is about permissions.
Another thing is that rather than using python (or conda) environments installed on your machine, I would heavily recommend looking at RCC and your robot templates. Specifically the conda.yaml. There you can isolate the environment that your robot uses so that do not have fiddle around with your system setup. In VS Code you can also get the “easy-mode” via our extension: Robocorp Code
I appreciate your input. To add to your comment about the permission error (since I’ve become quite the “expert” on it), I’m pretty sure it also may throw that error when it doesn’t recognize the input - either if the input is in a format the keyword doesn’t understand, or if it references a path that doesn’t exist/isn’t valid somehow.
I totally agree, and I do have it installed. It’s just that it’s been a while since I last used Robocorp, and I’ve done some drastic changes in the general vs code environment since then, and my hypothesis is that they also messed with the RC environment…?