-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Add cleanup implementation to filesystem backend #6919
Add cleanup implementation to filesystem backend #6919
Conversation
Codecov Report
@@ Coverage Diff @@
## master #6919 +/- ##
==========================================
- Coverage 89.21% 89.21% -0.01%
==========================================
Files 138 138
Lines 16678 16692 +14
Branches 2107 2112 +5
==========================================
+ Hits 14880 14892 +12
Misses 1577 1577
- Partials 221 223 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
This pull request introduces 2 alerts when merging 4660141 into 16959cd - view on LGTM.com new alerts:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you can try to improve the code coverage that would be really great
in backends.filesystem.FilesystemBackend.cleanup()
This pull request introduces 2 alerts when merging 9bdf8ae into 16959cd - view on LGTM.com new alerts:
|
Hi @auvipy, thank you for fast response and explanation. The pipelines in Celery project are great, but I need some advise on how to fix the coverage.
If no unit testing is run on Windows + FAT then the test can be enabled on Windows as is. Otherwise the only options are either add longer delay or ignore decreasing coverage. Please advise.
Thank you |
we can sqash commits while merge. i am ok with the current coverage. can you just check on pypy failures? |
From what I can understand:
exit code 3221225477 means segfault. And here is an issue that looks quite relevant: pytest-dev/pytest#6419. I'll try to rewrite with |
due to possible problems when testing under pypy-3.7, windows-2019 (pytest-dev/pytest#6419)
hi @auvipy, thank you for reviewing and approval. One last question: we have to maintain a number of boxes with Debian 9 -> Python 3.5 -> Celery 4.4. Can I somehow make a PR for backporting this feature to branch "4.x"? |
4.x is EOL. you should use pyenv to upgrade your python and should not rely on systems python. |
* Add cleanup implementation to filesystem backend * improve unit test coverage in backends.filesystem.FilesystemBackend.cleanup() * replace os.scandir() with os.listdir() due to possible problems when testing under pypy-3.7, windows-2019 (pytest-dev/pytest#6419)
Description
Filesystem back-end stores task results in files and currently has no
cleanup()
method. Without other ways of maintenance (e.g.logrotate
orsystemd-tmpfiles
) that will eventually overflow file system. This PR addscleanup()
implementation, which we use in our production.