-
Notifications
You must be signed in to change notification settings - Fork 63
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 automatic data download #932
Add automatic data download #932
Conversation
Hello @WilliamJamieson, Thank you for updating ! There are no PEP8 issues in this Pull Request. Comment last updated at 2024-11-22 21:09:18 UTC |
b9b2c2d
to
cadbcd8
Compare
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.
Found a small issue, but overall this looks great
Thanks @WilliamJamieson! This is a small point but I wanted to suggest we think about a different default path. FYI we are shortly going to be migrating “webbpsf” to “stpsf” to reflect that it’s Webb + Roman both. So perhaps we can preemptively avoid creating directories with the string “webbpsf” hard coded in them. |
This is fine with me, I only picked that as a default because that's what the docs used. I'm happy to change it to whatever you would like and update the docs to reflect the new default. |
@WilliamJamieson @mperrin, I'm actually okay with it staying at WebbPSF as long as this gets settled and merged in sooner than later. I will be doing plenty of replacements, so keeping it in line with the documentation is probably our best bet. Or if you choose not to use webbpsf, make sure you change the documentation to match. However if you think this will not be in within a week or so please change to something other than webbpsf (and include the doc change). |
cadbcd8
to
3e89b7c
Compare
I wonder if it is possible to hard code the URL and the default location and then just have the doc page use that value |
Note that I think it should be possible to have it pull the latest data version when this fails: Lines 214 to 238 in 629d73e
|
…ta if it isn't set
3e89b7c
to
3db3adf
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #932 +/- ##
===========================================
+ Coverage 62.15% 62.26% +0.10%
===========================================
Files 15 15
Lines 7016 7038 +22
===========================================
+ Hits 4361 4382 +21
- Misses 2655 2656 +1 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
This PR makes it so that instead of erroring out when
$WEBBPSF_PATH
is not set, that instead it attempts to download the data using the link in the documentation to the directory suggested for storing the data by the documentation. Note that no download will occur if the location suggested by the docs is non-empty; this saves users from constantly re-downloading the data. Warnings are issued to the user in the case that$WEBBPSF_PATH
is not set and then another warning if a download is attempted.