Extra stac validate#506
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b055b76ee3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| pystac_obj = pystac.Collection.from_dict(result) | ||
| else: | ||
| pystac_obj = pystac.read_dict(result) | ||
| pystac_obj.validate() |
There was a problem hiding this comment.
Add the PySTAC validation dependency before validating
When openeo_driver is installed normally, setup.py only pulls in pystac>=1.8.0; jsonschema is currently only listed in the test extras. PySTAC's validate() path requires its validation extra/jsonschema, so this new runtime call makes /jobs/{id}/results raise an ImportError/500 in a minimal production install as soon as a finished job result is returned. Either promote the validation dependency to runtime dependencies or avoid validating on the request path.
Useful? React with 👍 / 👎.
WIP. Too many changes for the moment.
@copilot