-
Notifications
You must be signed in to change notification settings - Fork 107
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
Fix behind EDL tests #480
Fix behind EDL tests #480
Conversation
👈 Launch a binder notebook on this branch for commit 6122fd6 I will automatically update this comment whenever this PR is modified 👈 Launch a binder notebook on this branch for commit 9756c50 👈 Launch a binder notebook on this branch for commit 4def499 👈 Launch a binder notebook on this branch for commit 127b78f 👈 Launch a binder notebook on this branch for commit ca7f027 👈 Launch a binder notebook on this branch for commit b277a9e 👈 Launch a binder notebook on this branch for commit 347b219 |
@all-contributors please add @lheagy for mentoring, review |
I've put up a pull request to add @lheagy! 🎉 |
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 to me, the only observation is to what users will see if they have hard-coded queries to V005.
@@ -23,6 +24,7 @@ def reg(): | |||
|
|||
@pytest.fixture(scope="module") | |||
def session(reg): | |||
os.environ = {"EARTHDATA_USERNAME": "icepyx_devteam"} |
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.
This is probably beyond the PR but have you all considered having a "default" username in case users want to use icepyx but don't have an EDL login? (don't quote me =) )
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.
We have, and we were told in no uncertain terms not to do it (it would also be very hard to do without somehow exposing the password). Since it's an ubiquitous problem, as you are well aware, we opted to just have users get an EDL (since they would have to just about anywhere except OA and SlideRule, I think), and we store the secrets for a dev account for CI testing (which isn't accessible for PRs from forks either).
obs = is2ref._get_custom_options(session, "ATL06", "005") | ||
with open("./icepyx/tests/ATL06v05_options.json") as exp_json: | ||
obs = is2ref._get_custom_options(session, "ATL06", "006") | ||
with open("./icepyx/tests/ATL06v06_options.json") as exp_json: |
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.
What would be the behavior if a script points to V005?
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.
As long as it's still available from NSIDC, the version specified will be ordered. If not, whatever error comes from NSIDC in the request will be surfaced. The default is to the most recent version, so we hard code the version into the test so that when a new version is released any changes in the options don't cause an error before we can manually update the json.
This reverts commit 34c36be.
Per #448, Earthdatalogin tests are failing since we upgraded to earthaccess for auth. This PR is to fix those tests so they run.