Repository navigation
fix: use maap-py v5 download_granule, pin maap-py, retry STAC fetches - #23
Merged
Merged
Conversation
- stage_in: call download_granule (downloadGranule is a raising stub in maap-py v5, so every asset download failed with an unexpected 'online_access_url' keyword error) - pin maap-py==5.1.0 in environment.yaml and the Dockerfile - create_inputs: retry transient HTTP errors (e.g. CMR 503) with backoff and a timeout, and raise a clear error instead of an AttributeError when a STAC input cannot be loaded - tests: maap-py signature contract test, retry and download_granule tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A UAT job for
mocca-v29601failed in input staging:MAAP.downloadGranule() got an unexpected keyword argument 'online_access_url'. In maap-py v5,downloadGranuleis a stub that raises; the replacement isdownload_granule(online_access_url, destination_path, overwrite). The Dockerfile installed maap-py unpinned, so the rebuilt image picked up 5.1.0.503madeload_json_from_urireturnNone, andstage_inthen crashed withAttributeError: 'NoneType' object has no attribute 'get'.Changes
stage_in.py: calldownload_granule.maap-py==5.1.0inenvironment.yamlanddocker/Dockerfile.create_inputs.py: retry HTTP fetches (4 attempts, backoff, 60s timeout) and raiseCould not load STAC JSON for input '<name>' from <uri>if loading still fails.download_granuletests. 77 tests pass locally with maap-py 5.1.0.Not changed
Per-asset download errors in
stage_inare still only printed, so a job can continue with empty catalogs. Worth a follow-up.After merge
Rebuild the image, then re-register/re-run on UAT to verify the optional
Directory?fix (550154d) end to end.