We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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
The current ItemSerializer.stac_to_db does not write any non inferred links to the links field in the items table.
ItemSerializer.stac_to_db
We propose : An adjustment to filter for derived_from in the input and then explicitly set the links value
derived_from
# Proposed mod to stac_fastapi/sqlalchemy/serializers.ItemSerializer.py from stac_fastapi.types.links import filter_links # ... class ItemSerializer(Serialiazer): # ... @classmethod def stac_to_db(...): # ... # Before instantiation of the database.Item, pull out derived_from link derived_from = None # Remove inferred link temp_links = filter_links(stac_data['links']) # Assign derived_from link for temp_link in temp_links: if temp_link['rel'] == 'derived_from': derived_from = [temp_link] break # ... return database.Item( # ... links=derived_from, # ... )
We would be happy to provide a PR. Thanks
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Uh oh!
There was an error while loading. Please reload this page.
The current
ItemSerializer.stac_to_db
does not write any non inferred links to the links field in the items table.We propose :
An adjustment to filter for
derived_from
in the input and then explicitly set the links valueWe would be happy to provide a PR.
Thanks
The text was updated successfully, but these errors were encountered: