-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
pytest.PytestWarning: open() missing required argument 'flags' (pos 2) #5626
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
Comments
I think it is quite a bad idea to chmod + retry in general - pytest should not mess with / change file permisisons. |
|
I disagree, especially on windows the following cases are fairly common:
|
here's (for example) what we use in pre-commit for the same issue: https://github.com/pre-commit/pre-commit/blob/95afd642f52b4d2a12ad605683c8f752e63530d0/pre_commit/util.py#L159-L172 |
Yes, I've created a PR already to fix it.. ;) As for the pre-commit function, it might still fail - one of the issues is that Have you never seen the issue / bug? |
pre-commit only retries a very specific set of functions and error conditions -- |
Yeah, just notices this also - it would not help in this case then altogether. Also I am not sure if |
force_writable_and_retry
might callopen
with missing args:The text was updated successfully, but these errors were encountered: