feat: add task to clean sandbox store#883
Merged
chrisburr merged 7 commits intoDIRACGrid:mainfrom Apr 14, 2026
Merged
Conversation
Contributor
|
Shall we add a unit test? |
Member
Author
|
I'm not sure what the answer should be for cases like this where tasks is just minimal boiler plate. |
chrisburr
commented
Apr 14, 2026
| from diracx.tasks.plumbing.retry_policies import ExponentialBackoff | ||
| from diracx.tasks.plumbing.schedules import CronSchedule | ||
|
|
||
| from .depends import NoTransaction |
Documentation build overview
Show files changed (2 files in total): 📝 2 modified | ➕ 0 added | ➖ 0 deleted
|
Member
Author
|
This branch had a broken import in
I've added several commits on top to fix this and prevent it happening again:
|
Add __init__.py to test subdirectories and diracx-tasks/src/diracx/tasks/jobs/ that were implicit namespace packages. Enable the INP ruff ruleset to prevent this class of bug in the future.
Re-export NoTransaction from the plumbing layer so task authors can import from diracx.tasks.depends rather than reaching into plumbing internals.
Use diracx.tasks.depends instead of the non-existent .depends module. Populate jobs/__init__.py to re-export CleanSandboxStoreTask as expected by the entry point definition.
Add a parametrized test that calls .load() on every registered diracx.* entry point. This catches broken imports that would otherwise only surface at runtime.
Update documentation examples to import NoTransaction and CallbackSpawner from diracx.tasks.depends instead of reaching into diracx.tasks.plumbing.depends. Also add CallbackSpawner to the public re-export.
f8067e0 to
bf7b1a2
Compare
chaen
approved these changes
Apr 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rebased the work of @natthan-pigoux based on how tasks evolved as a result of his original PR (chrisburr#1).