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

failing tests with pystac 1.12? #715

Open
soxofaan opened this issue Jan 28, 2025 · 2 comments
Open

failing tests with pystac 1.12? #715

soxofaan opened this issue Jan 28, 2025 · 2 comments

Comments

@soxofaan
Copy link
Member

unit tests started failing last week with:

=========================== short test summary info ============================
FAILED tests/test_metadata.py::test_metadata_from_stac_collection_bands_from_item_assets[False] - AssertionError: assert [] == ['2m_temperat...our_pressure']
  
  Right contains 4 more items, first extra item: '2m_temperature_max'
  
  Full diff:
  + []
  - [
  -     '2m_temperature_max',
  -     '2m_temperature_min',
  -     'dewpoint_temperature_mean',
  -     'vapour_pressure',
  - ]
FAILED tests/test_metadata.py::test_metadata_from_stac_collection_bands_from_item_assets[True] - AssertionError: assert [] == ['2m_temperat...our_pressure']
  
  Right contains 4 more items, first extra item: '2m_temperature_max'
  
  Full diff:
  + []
  - [
  -     '2m_temperature_max',
  -     '2m_temperature_min',
  -     'dewpoint_temperature_mean',
  -     'vapour_pressure',
  - ]
=========== 2 failed, 2267 passed, 9 skipped, 159 warnings in 24.04s ===========

I guess it's related to release 1.12 of pystac of last week

@soxofaan
Copy link
Member Author

did initial dive into this and it's a bit complicated:

  • test failure is due to not detecting bands anymore from stac collection where band names are in "item-assets" (extension)
  • pystac 1.12 started defaulting to stac 1.1.0
  • in stac 1.1.0, the functionality of the "item-assets" extension has been moved to core and is deprecated
  • pystac internally migrates the stac data to the default version (1.1.0 now), which erases the presence of the "item-assets" extensions, making the item-assets invisible

@soxofaan
Copy link
Member Author

as quick fix I already added a dependency pin pystac<1.12

longer term solution is of course fixing compatibility with newer pystac versions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant