Repository navigation
Conversation
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.
Summary
download_buildsaves the archive withfetch(artifact.url)from Node. Some editors return an artifact URL that is only reachable from the editor page, such as the root-relative path/api/projects/1/builds/5/download/My%20Game.zip. Node'sfetchcan't resolve it, so the download fails.http(s)://artifact URLs keep usingfetchexactly as before.download_asset.download_assetmoves tosrc/tools/transfer.ts(readTransfer) and is shared by both tools.download_assetbehaviour is unchanged: same size limits, base64 validation, temp file plus rename/link, overwrite handling and error messages.test/build-download.test.ts.Dependency
This needs the editor driver method
builds:artifact:start(buildId, maxInlineBytes). It replies with the same contract asfiles:download:start: either inline{ size, filename, mime, base64 }or chunked{ transferId, size, chunkSize, filename, mime }, read withfiles:download:readand closed withfiles:transfer:finish.Manual smoke test
https://artifact URL, then rundownload_buildwithformat: staticand a newoutputPath. Expected: the archive is saved tooutputPathas before, and the result reportsbuildId,pathandbytes.download_buildwith a newoutputPath. Expected: the archive is saved through the editor connection, it matches the build download byte for byte, and no.tmpfile is left next to it.download_buildagain with the sameoutputPathand nooverwrite. Expected: the call fails with "File already exists" and the existing file is unchanged.overwrite: true. Expected: the file is replaced.