Repository navigation
Pass the Zenodo draft ID from the Windows to the macOS upload - #325
Open
JuergenFleiss wants to merge 2 commits into
Open
JuergenFleiss wants to merge 2 commits into
JuergenFleiss wants to merge 2 commits into
Conversation
The macOS upload looked up the draft through ZENODO_CONCEPT_ID, which is unset before the first release, so appending the DMG failed. The Windows upload now writes its draft id to GITHUB_OUTPUT and the macOS job appends to exactly that draft, after checking that it is unpublished and has the release version. Tag runs share one concurrency group without cancelling, so two releases never write to the same draft. Branch test builds stay independent.
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
The macOS upload appends the DMG to the Zenodo draft that the Windows upload created. It found that draft through
ZENODO_CONCEPT_ID, which is not set before the first release, so the append failed.zenodo-upload.shwritesdraft-idtoGITHUB_OUTPUT,publish-to-zenodoexposes it, andpublish-macos-to-zenodopasses it asZENODO_DRAFT_ID.ZENODO_APPEND=1the script checks that the draft is unpublished and has the release version before it deletes or uploads any files.References
Split out of #323.
Screenshots / Examples
Verification Steps
uv run --no-sync pytest tests/unit/test_zenodo_upload.pyruns the script against a stubbed Zenodo API (10 cases: first release, existing concept, wrong version, published draft, retry).ZENODO_BASE=https://sandbox.zenodo.org) exercises it.