Skip to content

Pass the Zenodo draft ID from the Windows to the macOS upload - #325

Open
JuergenFleiss wants to merge 2 commits into
developfrom
bugfixes_zenodo_draft_id
Open

JuergenFleiss wants to merge 2 commits into
developfrom
bugfixes_zenodo_draft_id

Conversation

@JuergenFleiss

Copy link
Copy Markdown
Collaborator

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.sh writes draft-id to GITHUB_OUTPUT, publish-to-zenodo exposes it, and publish-macos-to-zenodo passes it as ZENODO_DRAFT_ID.
  • With ZENODO_APPEND=1 the script checks that the draft is unpublished and has the release version before it deletes or uploads any files.
  • Tag runs share one concurrency group without cancelling, so two releases never write to the same draft. Branch test builds stay independent.

References

Split out of #323.

Screenshots / Examples

Verification Steps

  • uv run --no-sync pytest tests/unit/test_zenodo_upload.py runs the script against a stubbed Zenodo API (10 cases: first release, existing concept, wrong version, published draft, retry).
  • Tagged publication is not verified yet; the next release (or a sandbox rehearsal with ZENODO_BASE=https://sandbox.zenodo.org) exercises it.

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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant