Skip to content

feat(sar): updated to SAR STAC Extension v1.3.2 - #1807

Open
sim13pods wants to merge 7 commits into
stac-utils:mainfrom
Terradue:t2_sar_update_132
Open

sim13pods wants to merge 7 commits into
stac-utils:mainfrom
Terradue:t2_sar_update_132

Conversation

@sim13pods

Copy link
Copy Markdown

Related Issue(s):

  • N/A

Description:

Version 1.3.2 includes range bandwidth (bandwidth, in GHz), relative burst numbers (relative_burst, starting at 1), beam identifiers (beam_ids), and compact polarizations (LH, LV, RH, RV, CH, and CV).

sar:product_type is deprecated in favor of product:type, and sar:instrument_mode is deprecated in favor of instrument_modes from the instruments extension. Both remain available for compatibility.

Spec: https://stac-extensions.github.io/sar/v1.3.2/schema.json

PR Checklist:

  • Pre-commit hooks pass (run pre-commit run --all-files)
  • Tests pass (run pytest)
  • Documentation has been updated to reflect changes, if applicable
  • This PR maintains or improves overall codebase code coverage
  • This PR's title is formatted per conventional commits

sim13pods and others added 3 commits September 14, 2026 11:36
Version 1.3.2 includes range bandwidth (`bandwidth`, in GHz), relative burst
numbers (`relative_burst`, starting at 1), beam identifiers (`beam_ids`), and
compact polarizations (`LH`, `LV`, `RH`, `RV`, `CH`, and `CV`).

`sar:product_type` is deprecated in favor of `product:type`, and
`sar:instrument_mode` is deprecated in favor of `instrument_modes` from the
instruments extension. Both remain available for compatibility.

Co-authored-by: Fabrice Brito <fabrice.brito@terradue.com>
Spec: https://stac-extensions.github.io/sar/v1.3.2/schema.json

@bmcandr bmcandr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @sim13pods, thanks for your contribution! Overall I think this looks great. Just two minor changes requested.

Comment thread extensions/sar/README.md Outdated
Deprecated in SAR v1.3.2 in favor of ``instrument_modes`` from the
instruments extension.
"""
return self._get_property(INSTRUMENT_MODE_PROP, str)

@bmcandr bmcandr Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gadomski what's your take on raising deprecation warnings in accessors for props? Existing deprecation warnings in the repo signal deprecations in the API, not the spec, and these accessors will stick around for a while. Just wondering if it's worth warning about, maybe in the setter, to nudge users towards current/future extension spec?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @bmcandr! My preference would be to document the spec deprecations in the accessors for now, while keeping their runtime behavior unchanged. These accessors remain supported for compatibility, and a DeprecationWarning could suggest that the Python API itself is scheduled for removal.

If we do want to nudge users toward the replacement fields, I agree that the setters would be the better place. Reading existing metadata should remain quiet, and assigning None to remove a deprecated field should not warn either. We could limit warnings to assignments of non-None values and explicitly identify the replacement: product:type for sar:product_type, and instrument_modes for sar:instrument_mode.

That distinction also matters for apply(), which calls these setters even when the optional arguments are omitted.

@gadomski, happy to follow whichever policy you think fits PySTAC best. It would be useful to apply the same approach consistently across extensions.

Comment thread extensions/sar/tests/test_sar.py Outdated

This branch has not been deployed

No deployments
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.

2 participants