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
DM-36412: Add new env var DAF_BUTLER_CACHE_DIRECTORY_IF_UNSET #738
Conversation
Codecov ReportBase: 84.79% // Head: 84.80% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #738 +/- ##
==========================================
+ Coverage 84.79% 84.80% +0.01%
==========================================
Files 254 254
Lines 32911 32967 +56
Branches 5618 5630 +12
==========================================
+ Hits 27907 27959 +52
- Misses 3783 3785 +2
- Partials 1221 1223 +2
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
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.
Looks good, one easy question.
This only overrides the cache directory if nothing has set it explicitly from config or the other env var.
If multiple processes are sharing a cache directory and caching on read then it is possible that the other process has already copied the dataset into the cache. We therefore need to check before we try to copy it.
…able Also change the behavior such that if that variable gets set after the cache manager has been instantiated, it will still use that environment variable to make the default cache directory if it has not yet been defined.
This only overrides the cache directory if nothing has set it explicitly from config or the other env var.
Checklist
doc/changes