Skip to content

Dispatch downstream version bumps on stable publish#5817

Open
Topherhindman wants to merge 1 commit into
mainfrom
chore/dispatch-downstream-bumps
Open

Dispatch downstream version bumps on stable publish#5817
Topherhindman wants to merge 1 commit into
mainfrom
chore/dispatch-downstream-bumps

Conversation

@Topherhindman
Copy link
Copy Markdown
Contributor

After a release/vX.Y.Z PR merges and PyPI publish succeeds, fires a repository_dispatch to TARGET_REPO so we can open a PR bumping the pinned livekit-agents version in downstream consumers (e.g. agent-starter-python).

Stability is inferred from the PR head ref pattern (release/vX.Y.Z), which mirrors the user's choice in the bump job (patch/minor/major/ promote produce X.Y.Z; *-rc variants produce X.Y.Z.rcN and are skipped). This avoids an unnecessary checkout and a version-string regex.

Republish retries are intentionally not dispatched here. Downstream sync workflow exposes a workflow_dispatch input for that case.

After a release/vX.Y.Z PR merges and PyPI publish succeeds, fires a
repository_dispatch to TARGET_REPO so internal-actions can open a PR
bumping the pinned livekit-agents version in downstream consumers
(e.g. agent-starter-python).

Stability is inferred from the PR head ref pattern (release/vX.Y.Z),
which mirrors the user's choice in the bump job (patch/minor/major/
promote produce X.Y.Z; *-rc variants produce X.Y.Z.rcN and are skipped).
This avoids an unnecessary checkout and a version-string regex.

Republish retries are intentionally not dispatched here — the
internal-actions sync workflow exposes a workflow_dispatch input for
that case.
@chenghao-mou chenghao-mou requested a review from a team May 22, 2026 20:57
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

View 2 additional findings in Devin Review.

Open in Devin Review

-f event_type="livekit-agents-published" \
-f client_payload[version]="$VERSION" \
-f client_payload[source_repo]="${{ github.repository }}" \
-f client_payload[source_sha]="${{ github.sha }}"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 github.sha sends temporary merge commit SHA instead of actual merge commit SHA

In the dispatch-downstream-bumps job, ${{ github.sha }} is used for source_sha in the dispatch payload. For pull_request events, github.sha resolves to the temporary merge commit on refs/pull/<number>/merge, not the actual merge commit on the base branch. This temporary ref can be garbage-collected by GitHub. Every other place in this workflow that references the commit SHA for a merged PR uses github.event.pull_request.merge_commit_sha instead (publish.yml:150, publish.yml:190, publish.yml:255). The downstream consumer would receive a potentially-ephemeral SHA that doesn't correspond to any permanent commit on the target branch.

Suggested change
-f client_payload[source_sha]="${{ github.sha }}"
-f client_payload[source_sha]="${{ github.event.pull_request.merge_commit_sha }}"
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

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