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

Relax search link requirements #160

Merged
merged 2 commits into from
May 18, 2022
Merged

Conversation

gadomski
Copy link
Member

@gadomski gadomski commented May 16, 2022

Related Issue(s):

Description:
While "search" links are required to be media_type=GeoJSON by v1.0.0-rc.1 of the STAC-API spec, some older servers (e.g.
https://earth-search.aws.element84.com/v0/), use JSON. This patch adds a require_geojson_link parameter to both Client.open and Client.search. This parameter relaxes the media_type constraint in the default case, while allowing a user to opt-in to the stricter behavior if they would like.

PR Checklist:

  • Code is formatted
  • Tests pass
  • Changes are added to the CHANGELOG

While "search" links are required to be media_type=GeoJSON by
v1.0.0-rc.1 of the STAC-API spec, some older servers (e.g.
https://earth-search.aws.element84.com/v0/), use JSON. This patch adds a
`require_geojson_link` parameter to both Client.open and Client.search.
This parameter relaxes the media_type constraint in the default case,
while allowing a user to opt-in to the stricter behavior if they would
like.
@gadomski gadomski added this to the 0.4.0 milestone May 16, 2022
@gadomski gadomski merged commit 7bedea4 into main May 18, 2022
@gadomski gadomski deleted the relax-search-link-requirements branch May 18, 2022 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0.3.3 does not support/has trouble with stac api version < 1.0.0
2 participants