Skip to content

ci(api-docs): build the reference from the latest stable SDK tag - #15

Open
rahlk wants to merge 1 commit into
astrofrom
fix/issue-12-stable-sdk-tag
Open

rahlk wants to merge 1 commit into
astrofrom
fix/issue-12-stable-sdk-tag

Conversation

@rahlk

@rahlk rahlk commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Closes #12.

The deploy built the published Python API reference from v2.0.0-rc.8, not from the v2.0.0 release. The cause is git tag --sort=-v:refname | head -n1: git's version sort puts -rc tags above the release.

Changes

  • deploy.yml: select the newest stable tag (^v[0-9]+\.[0-9]+\.[0-9]+$). Install griffe from scripts/requirements.txt, as update-api-docs.yml does.
  • update-api-docs.yml: use the same stable-tag selection for the fallback. Skip pre-release dispatches (a ref that contains -), because python-sdk dispatches sdk-release for -rc tags too.

Test

I ran the selection command under set -euo pipefail on a clone of python-sdk:

Tags in the repo Old command New command
current tags v2.0.0-rc.8 v2.0.0
plus a test tag v2.1.0-rc.1 v2.1.0-rc.1 v2.0.0
plus test tags v2.1.0-rc.1 and v2.0.1 v2.1.0-rc.1 v2.0.1
no tags empty the step fails (exit 1)

Both workflow files parse as YAML.

Merge order

Merge this first, then #16 (guides, examples and install pages), then #17 (the API reference). The first deploy after #17 then builds the reference from v2.0.0.

git tag --sort=-v:refname puts v2.0.0-rc.8 above v2.0.0, so every deploy
built the published reference from the release candidate. Select stable
vX.Y.Z tags only, in deploy.yml and in the update-api-docs.yml fallback.

update-api-docs.yml now skips pre-release dispatches, and deploy.yml
installs griffe from scripts/requirements.txt like update-api-docs.yml.

This branch has not been deployed

No deployments
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.

Deploy builds the API reference from a pre-release SDK tag

1 participant