You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all thanks for this library, it is very helpful for us! I have a question which is touching this issue. When we are doing earthaccess.search_data() we are login in via environment variables. So far so good, under https://urs.earthdata.nasa.gov/users/username/user_tokens we can see that two new tokens are created. I guess these are CMR Tokens? However, these tokens expire after 2 months and are not re-created and when we continue to use earthaccess we are getting RuntimeError('{"errors":["Token [Bearer eyJXXXI4SIQ] has expired. Note the token value has been partially redacted."]}'. This is solved by just deleting the Bearer Tokens, which triggers a re-creation.
Token regeneration is not automatic, actually is not part of the top level API. It could be automatic if we encounter an expired token, as of now one can do this:
Thanks for opening this issue, I saw the part of the code you linked and wondered why that did not work as expected for us.
Are you able to reproduce the behaviour?
Originally posted by @fwfichtner in #484 (comment)
Originally posted by @betolink in #484 (comment)
To implement this, I think we need to look for this specific response from EDL and do a token refresh when we see it.
The text was updated successfully, but these errors were encountered: