-
Notifications
You must be signed in to change notification settings - Fork 220
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
Transport
& pytest
: garbage cannot be removed [Errno 39]
#6751
Comments
Hey if Its not deleting Why not delete it Manually and then runs the Test |
Because we don't want to do it manually, and because it should not happen. :-) |
Can't we can use Force method to delete |
The issue me relate to pytest-dev/pytest#12381, which may or may not resolved from our side. If someone what to pick this issue, would be nice to have a deep understanding on problem of data racing introduced by pytest-xdist and how to avoid it nicely. |
Well I am new to this and don’t have deep understanding but still I will try to resolve this issue |
hello @khsrali , is this issue still open? If yes, can I proceed with this ? |
Hi @crs7617, I think also @ayushjariyal showed some interest working on this. |
@khsrali I am working on it. Right now, my semester exams are going on, so I am unable to give my full time to this. However, I am trying my best. |
It's all good, no hurry! take your time. |
@khsrali Thanks for the update! if there's anything I can help with, feel free to let me know. |
@khsrali, I noticed that @ayushjariyal is currently working on issue #6728. I just wanted to clarify if issue #6751 is separate from that, or if they are related. If they are distinct, I’d be happy to proceed with #6751. Let me know what you think! |
They are independent issues. |
alright, thanks for the clarification ! |
Hey @khsrali , I investigated the issue thoroughly and found that Aiida's codebase does not have any errors related to garbage file management. The problem lies in Pyenv, where some directories are not being deleted properly because they are still not empty when Pytest attempts to remove them in pathlib.py. To resolve this, I updated the function to forcefully delete those files, and after the update, the warnings no longer appeared. Could you please let me know if I missed anything or made any mistakes? |
Hi @ayushjariyal, |
Hi @khsrali ,
Since it belongs to pyenv, it might make sense to fix this upstream, but I'm not quite sure how to go about it. |
You can find it on github here: https://github.com/pytest-dev/pytest/blob/main/src/_pytest/pathlib.py#L162 |
Alright! Thanks @ayushjariyal ! in that case, I think we should open an issue and ask Once the issue is opened, please also put a link here, so we can track to see what happens. Cheers! |
Sure! I'll open and issue with pytest. |
I opened an issue regarding this problem. You can find it here: |
Confirm the Issue Scope Potential Workarounds Upstream Considerations Further Investigation |
@adityagh006, chatgpt? 🙃 It's ok to use chatgpt for coding and development. |
To reproduce
When running
pytest test_all_plugins.py -s
, despite all tests passing successful, a long tail of warning messages is printed:that
pytest
cannot clean the garbage.To be investigated. Also pinging @unkcpz
The text was updated successfully, but these errors were encountered: