-
Notifications
You must be signed in to change notification settings - Fork 110
Enable context extension for Search operations - search support for common STAC clients #207
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
Comments
If help is needed, I can dirt hands on this. |
I think it all comes down to the Context extension being enable or not on the API https://github.com/stac-utils/stac-fastapi/blob/master/stac_fastapi/extensions/stac_fastapi/extensions/core/context.py |
Thanks for reverting Vincent. |
@jaysnm Exactly, you'll need to implement or Enable the Context extension for the DB backend you are using (PGSTAC or SQLachemy or ...). FYI the context extension has been added to the SQLAlchemy backend but not in PGSTAC I think. if you are using SQLAlchemy backend you just need to add |
Thanks @vincentsarago |
@jaysnm both pystac-client and stac-fastapi are in development as the stac-api specification, all those 3 are moving at different speed so sadly I think errors like this are expected. |
I admittedly have never tried calling stac-fastapi from any of the client side libraries, but I'd like to eventually get to a point where we are doing integration tests between stac-fastapi and other tooling libraries like pystac-client etc. I will say that we are working on building a python client for stac-fastapi which will likely be pushed to this repo as a new submodule but that doesn't forgo the need for integrating with other client libraries. |
Thanks a lot for heads up. I will spend the next couple of hours looking at pystac-client/stac-fastapi for a possible hack. If I'm lucky, I will share my working. Otherwise I will wait for "the submodule" as Jeff puts it. |
@jaysnm There are some changes in #165 to return the proper conformance URLs, this should let the API pass the pystac-client conformance checks. Fixing the conformance classes (ref #169) isn't relevant to the purpose of that PR (adding the filter extension) so maybe it's worth pulling that code into a different PR and getting it merged into master. |
Thanks @geospatial-jeff |
I'll note that the context extension is not required by the STAC API spec, nor pystac_client in it's most recent version. pgstac doesn't support the context extension in the version currently used in the rep, but does enable it in the most recent releases. |
Thank you all for great comments and kind responses. I'm closing this issue for obvious reasons, it is resolved by #211. In case you are of a differing opinion, please feel free to re-open the issue or open a new ticket. Thank you all and sorry for the inconvenience. |
* enable search context extension #207 * advertise conformance to STAC Spec 1.0.0-beta.2 * did run "make test" to let isort do its thing * Enable `ContextExtension` by default Co-authored-by: Rob Emanuele <[email protected]>
Many thanks to maintainers of this cool project.
I'm not sure if this this a feature request or bug report, nonetheless, this is what I have noted on
/search
functionalityI have tried catalog search using both sat-search and pystac-client but none seems to have native/compatible support.
While
sat-search
expects/search
to return statistics of features matching query with no payload of feature items whenlimit
is set to0
, stac-fastapi responds with404 Error: Not Found
Response
Without
limit=0
Executing a similar request on
https://earth-search.aws.element84.com/v0/search
withlimit=0
onsentinel-s2-l1c
collection yieldsIn addition to this disparity, result payload from stac-fastapi is missing
context
and/ornumberMatched
key. This makessat-search
return 0 count for items matching search terms. Please see this fork for my temp fix on sat-search side.The incompatibility is not a
sat-search
problem becausepystac-client
is failing on search withNotImplementedError
The text was updated successfully, but these errors were encountered: