-
Notifications
You must be signed in to change notification settings - Fork 83
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
Cache PDB downloads #260
Cache PDB downloads #260
Conversation
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.
I think you nailed it first try. This adds the feature exactly as I was hoping and from my testing works perfectly!
I don't know how you'd do it, but potentially adding some kind of test would be good. Testing is tricky with the addon as you have to run them through the headless scripts, but maybe a test that runs and checks that the file has been downloaded would be all we need.
Otherwise fabulous work and thanks for the contributions, it's basically ready to be merged with a couple of minor changes.
I was already getting a bit concerned with having to keep track of the several definitions of the default cache site, so I created Otherwise, made all the changes you mentioned. The test I added only checks whether a file with the right name got downloaded --- I don't do any checks to make sure it's the right structure. |
I guess, looking at it, the |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #260 +/- ##
==========================================
+ Coverage 53.71% 53.73% +0.01%
==========================================
Files 15 15
Lines 1949 1952 +3
==========================================
+ Hits 1047 1049 +2
- Misses 902 903 +1
☔ View full report in Codecov by Sentry. |
For the |
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.
Looking good! Minor comments but otherwise it's good to merge once those are done
Agreed on both fronts. Even if I can think of a reason to use an external config it should be a different PR. And using None makes more sense for the functions. |
Support for caching PDB downloads
Support for caching PDB downloads
Adds biotite caching, resolving #256. Tested by downloading a structure, turning off wifi, and re-loading it successfully. The cache folder is also created and populated with models.
I'm mostly working on this one to figure out how to add stuff to MolNodes, but it does work. It looks like there is a lot of duplicating default values --- I tried to copy your style but I'd be happy with feedback.