Skip to content
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

Data access tutorial #11

Merged
merged 14 commits into from
Aug 16, 2024

Conversation

mikala-nsidc
Copy link
Contributor

@mikala-nsidc mikala-nsidc commented Aug 9, 2024

the website build through GitHub actions is failing, because the notebooks need to authenticate with Earthdata Login. We're doing that authentication with earthaccess and so we could provide credentials to the notebook via the following environment variables
EARTHDATA_USERNAME, EARTHDATA_PASSWORD
could you set those as repository secrets? do you already have a shared account for this?

@scottyhq scottyhq added the preview Create a website preview label Aug 9, 2024
Copy link

github-actions bot commented Aug 9, 2024

@mikala-nsidc mikala-nsidc marked this pull request as ready for review August 9, 2024 21:50
@mikala-nsidc
Copy link
Contributor Author

Adding the Data Access chapter to the SnowEx website-2024 Jupyter Book.

@scottyhq
Copy link
Member

EARTHDATA_USERNAME, EARTHDATA_PASSWORD
could you set those as repository secrets? do you already have a shared account for this?

ref: https://earthaccess.readthedocs.io/en/latest/howto/authenticate/#authenticate-with-earthdata-login

I just added them @mikala-nsidc! So the CI workflows will have access via a bot "uwhackweek" account

conda/README.md Outdated
Copy link
Member

@scottyhq scottyhq Aug 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can remove the conda/ folder from this PR (I'll do a separate update of the CI environment to match cryocloud in #12)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @scottyhq ! Just to clarify - should I revert my commit that contains the change requests to anything under conda/? Or do you mean actually remove the Conda/ folder from my fork and push that change? Thanks for any help!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I meant revert your change or copy from the new main branch. I think there are different ways to do this. Maybe this?:

git checkout main
git pull upstream main
gh pr checkout 11 
git merge main
git checkout HEAD -- conda/
git push

@mikala-nsidc
Copy link
Contributor Author

@scottyhq I reverted the commit I made yesterday that requested changes to files in conda/. Let me know if this works, or if I need to do something else to make the pull request mergeable. Thanks!

Comment on lines 16 to 20
<figure>
<center>
<img width="80%" src='./images/DAAC_map_with_ECS.jpg'/>
</center>
</figure>
Copy link
Member

@scottyhq scottyhq Aug 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This syntax is not rendering on CryoCloud, could you please try this syntax https://mystmd.org/guide/figures#image-directive

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do!

@scottyhq
Copy link
Member

After #13 if you merge the main branch again I think your notebooks will pick up the EARTHDATA credentials and successfully execute

"source": [
"downloaded_files = earthaccess.download(\n",
" results,\n",
" local_path='./Downloads',\n",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider changing the download path to /tmp for tutorial data (https://docs.2i2c.org/user/topics/data/filesystem/#the-tmp-directory)

@JessicaS11
Copy link
Member

@mikala-nsidc This is looking great. I would love to see your and Gail's hard work putting this content together recognized if you're comfortable adding your names to the notebooks and/or overview page.

@mikala-nsidc
Copy link
Contributor Author

I forgot to add in my commit message that I also changed the format of the figures, so hopefully they will render in the book in cryocloud now. Let me know, if not!

@mikala-nsidc
Copy link
Contributor Author

That last force push was to overwrite the commits by egreckase and go back to where we were prior to those.

@JessicaS11 JessicaS11 removed the preview Create a website preview label Aug 16, 2024
@JessicaS11 JessicaS11 added the preview Create a website preview label Aug 16, 2024
@mikala-nsidc
Copy link
Contributor Author

I see those commits @scottyhq ! Thanks for adding those for me.

@scottyhq scottyhq merged commit e2266d8 into snowex-hackweek:main Aug 16, 2024
4 checks passed
@mikala-nsidc mikala-nsidc deleted the data-access-tutorial branch August 16, 2024 21:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
preview Create a website preview
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants