-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Temporary files: Permission denied #2547
Comments
I have no exact solution, but let me share my investigation, maybe it will bring some ideas. I cloned your repo and was able to reproduce the problem. Then connected to build worker with RDP and was able to reproduce it manually in command line (was needed to set Can it be some concurrency issue? I have no knowledge about And finally, does it work when being executed the same way on local Windows machine? |
Thanks for your investigation!
I doubt it, since Pytest without any plugins does not use concurrent testing AFAIK.
I could add some retry logic, although that would only be a solution for debugging the problem.
I will check. |
Okay, I solved the problem. Actually, it was not a problem about permissions at all. It was a problem of how with tempfile.NamedTemporaryFile(suffix=extension, delete=False) as my_file:
filename = my_file.name
with can.Logger(filename) as writer:
self.assertIsInstance(writer, klass)
# delete "manually" afterwards |
Great, thanks for the update! |
I am trying to write some temporary files using Python's
NamedTemporaryFile
and alike, and get errors:This occurs in the python-can repo, for example right here. The .appveyor.yml file looks like this:
Note: The
before_test
section was added in hope to solve the problem, but didn't help.The text was updated successfully, but these errors were encountered: