Skip to content

Commit

Permalink
proper deprecation of auth.refresh_tokens()
Browse files Browse the repository at this point in the history
  • Loading branch information
fwfichtner committed Aug 2, 2024
1 parent 8663adc commit 37b2370
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### Unreleased

- Changed auth strategy to use `find_or_create_token` endpoint ([#484](https://github.com/nsidc/earthaccess/issues/484)) ([**@fwfichtner**](https://github.com/fwfichtner)
- Changed auth strategy to use `find_or_create_token` endpoint, deprecated `auth.refresh_tokens()` ([#484](https://github.com/nsidc/earthaccess/issues/484)) ([**@fwfichtner**](https://github.com/fwfichtner)
- Deprecate `earthaccess.get_s3fs_session` and `Store.get_s3fs_session`. Use
`earthaccess.get_s3_filesystem` and `Store.get_s3_filesystem`, respectively,
instead ([#766](https://github.com/nsidc/earthaccess/issues/766))([**@Sherwin-14**](https://github.com/Sherwin-14))
Expand Down
5 changes: 5 additions & 0 deletions earthaccess/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

import requests # type: ignore
from tinynetrc import Netrc
from typing_extensions import deprecated

from .daac import DAACS
from .system import PROD, System
Expand Down Expand Up @@ -125,6 +126,10 @@ def _set_earthdata_system(self, system: System) -> None:
)
self._apps_url = f"https://{self.system.edl_hostname}/application_search"

@deprecated("Refresh tokens has been deprecated and is not necessary anymore.")
def refresh_tokens(self) -> bool:
return self.authenticated

def get_s3_credentials(
self,
daac: Optional[str] = None,
Expand Down

0 comments on commit 37b2370

Please sign in to comment.