fix(download): use direct_url so filename keeps its extension#130
Merged
fix(download): use direct_url so filename keeps its extension#130
Conversation
The REST migration mapped ApiImage.download.file_url -> ImageInfo.file_url, but that field is the pretty mirror-selector URL (successor of the legacy redi_url) without a file extension. Pre-migration the download pipeline consumed the legacy file_url, which is now exposed as direct_url. Passing direct_url restores the original behavior: the backend extracts a filename with a proper extension, and decompression plus QDL extraction work again.
❌ Test BuildsVersion:
ℹ️ About these builds
|
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.
The REST API migration mapped
ApiImage.download.file_urltoImageInfo.file_url, but that field is the pretty mirror-selector URL (successor of the legacyredi_url) and has no file extension. Pre-migration the download pipeline consumed the legacyfile_url, which on the new API is exposed asdirect_url.The side effect is that downloaded images get saved with names like
Noble_vendor_gnome:needs_decompressioncan't recognise the format, XZ data is written raw to the SD card, and the QDL extractor chokes on a TAR header that's actually7zXZmagic bytes. Passingdirect_urlat the one call site restores the pre-migration behaviour — the backend extracts a filename with the correct extension and the decompression / QDL pipelines work again.file_urlstays where it belongs: UI keys and per-image storage identifiers.