Skip to content

feat: mlm extension added missing migrations, bugfixes - #1777

Open
jonas-hurst wants to merge 7 commits into
stac-utils:mainfrom
jonas-hurst:mlm-refactor
Open

jonas-hurst wants to merge 7 commits into
stac-utils:mainfrom
jonas-hurst:mlm-refactor

Conversation

@jonas-hurst

@jonas-hurst jonas-hurst commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor

Description:
Continuation of #1571
Adjusted mlm extension code to the new extension framework. Added missing migrations, fixed bugs and typos

Did not make any code changes since reviewed by @romeokienzler in the last PR. Only moved the code to match the new extension framework.

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

@jonas-hurst

jonas-hurst commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor Author

Regarding question #1571 (review) :
There are extension fields (e.g. mlm:name, mlm:architecture) that can be applied on the item level or the asset level. Further, there are fields that exclusively extend the asset (e.g. mlm:artifact_type). Hence the difference between AssetGeneralMLMExtension and AssetDetailedMLMExtension.
When extending an asset we need to figure out which of the two we should use, so presence of required property mlm:architecture indicates that we deal with AssetDetailedMLMExtension.
The spec states: the mlm:name should always be provided in the Item properties, so using the required field mlm:architecture instead in the asset is a better indicator.

@jonas-hurst jonas-hurst mentioned this pull request Jul 24, 2026
5 tasks done
@jonas-hurst

jonas-hurst commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor Author

to resolve mypy issues:

  • installed types-requests library into dev group (reported by cicd pipelines)
  • removed type:ignore comments from core/pystac/utils.py
core/pystac/utils.py:490: error: Unused "type: ignore" comment  [unused-ignore]
core/pystac/utils.py:493: error: Unused "type: ignore" comment  [unused-ignore]
core/pystac/utils.py:494: error: Unused "type: ignore" comment  [unused-ignore]
Found 3 errors in 1 file (checked 127 source files)

@jonas-hurst

This comment was marked as resolved.

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