Skip to content

ci: migrate workflow-dispatch to benc-uk/workflow-dispatch v1.3.0#986

Draft
Aaron ("AJ") Steers (aaronsteers) wants to merge 4 commits intomainfrom
devin/1771663959-migrate-workflow-dispatch
Draft

ci: migrate workflow-dispatch to benc-uk/workflow-dispatch v1.3.0#986
Aaron ("AJ") Steers (aaronsteers) wants to merge 4 commits intomainfrom
devin/1771663959-migrate-workflow-dispatch

Conversation

@aaronsteers
Copy link
Contributor

@aaronsteers Aaron ("AJ") Steers (aaronsteers) commented Feb 21, 2026

ci: migrate workflow-dispatch to benc-uk/workflow-dispatch v1.3.0

Summary

Migrates the prerelease workflow from the-actions-org/workflow-dispatch@v4 (a fork) to the upstream benc-uk/workflow-dispatch@v1.3.0, which now uses GitHub's new return_run_details API parameter for deterministic run ID resolution instead of polling listWorkflowRuns. See benc-uk/workflow-dispatch#83.

Changes:

  • Action: the-actions-org/workflow-dispatch@v4benc-uk/workflow-dispatch@a54f9d1 (v1.3.0, SHA-pinned)
  • Timeout input: wait-for-completion-timeout: 30mwait-timeout-seconds: 1800
  • Output rename: workflow-urlrunUrlHtml
  • Output removed: workflow-conclusion (not available in benc-uk; replaced by explicit gh run view conclusion check — see below)
  • Conclusion safeguard added: New "Verify dispatched workflow succeeded" step that calls gh run view with the runId output to check the dispatched run's conclusion and fails the job on non-success. This is necessary because benc-uk v1.3.0's wait-for-completion only checks status (completed vs. in-progress), not conclusion (success vs. failure) — it logs a warning instead of failing the step.

Review & Testing Checklist for Human

  • End-to-end test: Trigger a prerelease on a test PR (/prerelease slash command) and verify: (a) the workflow dispatches successfully, (b) the status comment posts with a valid workflow URL, (c) a deliberately failing publish still produces the failure comment. This is the only way to validate these changes — CI cannot exercise the dispatch path.
  • Conclusion check behavior: The new gh run view verification step is untested. Confirm it correctly reads the runId output from the dispatch step and that the conclusion value is "success" for a passing run. Edge case: if the 1800s wait timeout expires, the run may still be in-progress — conclusion would be null/empty, which the != "success" check handles by failing, but verify this is the desired behavior.
  • Output mapping: Confirm steps.dispatch.outputs.runUrlHtml produces a valid URL in the PR success/failure comments.

Notes

  • The oncall repo already uses benc-uk/workflow-dispatch@v1, and the floating v1 tag now points to v1.3.0 — no changes needed there.
  • benc-uk/workflow-dispatch v1.3.0 was merged 9 hours ago — it's very fresh. Worth monitoring for any upstream issues.

Requested by: Aaron ("AJ") Steers (@aaronsteers)
Link to Devin run

Summary by CodeRabbit

  • Chores
    • Updated CI workflow automation: replaced the external dispatch step, adjusted timeout handling, and consolidated public workflow outputs for clearer reporting and reliability. These are backend automation changes that do not affect the app’s UI or user-facing features.

Open with Devin

Migrate from the-actions-org/workflow-dispatch@v4 to
benc-uk/workflow-dispatch@v1.3.0 which uses the new GitHub API
return_run_details parameter for deterministic run ID resolution.

Changes:
- Pin to benc-uk/workflow-dispatch@a54f9d1 (v1.3.0)
- wait-for-completion-timeout -> wait-timeout-seconds (1800s = 30m)
- workflow-url output -> runUrlHtml output
- Remove workflow-conclusion output (not available in benc-uk)

Co-Authored-By: AJ Steers <aj@airbyte.io>
@devin-ai-integration
Copy link
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

github-actions[bot]

This comment was marked as resolved.

@github-actions
Copy link

👋 Greetings, Airbyte Team Member!

Here are some helpful tips and reminders for your convenience.

💡 Show Tips and Tricks

Testing This PyAirbyte Version

You can test this version of PyAirbyte using the following:

# Run PyAirbyte CLI from this branch:
uvx --from 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1771663959-migrate-workflow-dispatch' pyairbyte --help

# Install PyAirbyte from this branch for development:
pip install 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1771663959-migrate-workflow-dispatch'

PR Slash Commands

Airbyte Maintainers can execute the following slash commands on your PR:

  • /fix-pr - Fixes most formatting and linting issues
  • /uv-lock - Updates uv.lock file
  • /test-pr - Runs tests with the updated PyAirbyte
  • /prerelease - Builds and publishes a prerelease version to PyPI
📚 Show Repo Guidance

Helpful Resources

Community Support

Questions? Join the #pyairbyte channel in our Slack workspace.

📝 Edit this welcome message.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 21, 2026

📝 Walkthrough

Walkthrough

Swaps the workflow-dispatch action implementation, renames the completion timeout parameter to seconds, and updates public outputs: removes workflow-conclusion and maps workflow-url to steps.dispatch.outputs.runUrlHtml. No other control-flow changes were introduced.

Changes

Cohort / File(s) Summary
Workflow dispatch config
.github/workflows/prerelease-command.yml
Replaced the-actions-org/workflow-dispatch@v4 with benc-uk/workflow-dispatch@a54f9d194fed472732282ed1597dc4909e4b4080 (v1.3.0). Replaced wait-for-completion-timeout: 30m with wait-timeout-seconds: 1800. Removed public output workflow-conclusion; updated public output workflow-url to reference steps.dispatch.outputs.runUrlHtml. Updated dispatch step parameter and output names to match the new action.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Did you verify that the new action exposes runUrlHtml and that wait-timeout-seconds: 1800 preserves the intended 30-minute behavior? wdyt?

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: migrating the workflow-dispatch action to a newer upstream version with version specification.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch devin/1771663959-migrate-workflow-dispatch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

coderabbitai[bot]

This comment was marked as resolved.

benc-uk/workflow-dispatch v1.3.0 does not fail the step when the
dispatched workflow fails (it only checks status, not conclusion).
Add an explicit gh run view check to fail the job properly when
the dispatched workflow concludes with anything other than success.

Co-Authored-By: AJ Steers <aj@airbyte.io>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
.github/workflows/prerelease-command.yml (1)

93-102: Nice — this directly addresses the failure propagation gap from the previous review.

The gh run view + conclusion check is the right approach given that benc-uk v1.3.0 doesn't fail the step on a non-success dispatched run. A couple of small observations:

  1. Hardcoded repo: Line 95 uses --repo airbytehq/PyAirbyte. Would --repo ${{ github.repository }} be slightly more portable here, wdyt? It's the same value in practice, but avoids the coupling if the workflow ever gets forked or the repo gets renamed.

  2. Timeout edge case: If the 1800s wait expires (benc-uk logs a warning but doesn't fail), this step would still run and conclusion would likely be null/empty since the run is still in-progress. The != "success" check handles that correctly — the job will fail. Just wanted to confirm that's the intended behavior.

Optional: use github.repository instead of hardcoded repo
     - name: Verify dispatched workflow succeeded
       run: |
-        CONCLUSION=$(gh run view ${{ steps.dispatch.outputs.runId }} --repo airbytehq/PyAirbyte --json conclusion -q .conclusion)
+        CONCLUSION=$(gh run view ${{ steps.dispatch.outputs.runId }} --repo ${{ github.repository }} --json conclusion -q .conclusion)
         echo "Dispatched workflow conclusion: $CONCLUSION"
         if [ "$CONCLUSION" != "success" ]; then
           echo "::error::Dispatched workflow concluded with: $CONCLUSION"
           exit 1
         fi
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/prerelease-command.yml around lines 93 - 102, Replace the
hardcoded repo in the gh command so the step uses the current repository
dynamically: update the gh invocation that uses "gh run view ${{
steps.dispatch.outputs.runId }} --repo airbytehq/PyAirbyte" to use --repo ${{
github.repository }} (keeping the same runId reference
steps.dispatch.outputs.runId and GH_TOKEN env) to avoid coupling to a specific
repo; leave the existing conclusion check logic as-is to treat null/empty
conclusions (e.g., from timeout) as failures.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In @.github/workflows/prerelease-command.yml:
- Around line 93-102: Replace the hardcoded repo in the gh command so the step
uses the current repository dynamically: update the gh invocation that uses "gh
run view ${{ steps.dispatch.outputs.runId }} --repo airbytehq/PyAirbyte" to use
--repo ${{ github.repository }} (keeping the same runId reference
steps.dispatch.outputs.runId and GH_TOKEN env) to avoid coupling to a specific
repo; leave the existing conclusion check logic as-is to treat null/empty
conclusions (e.g., from timeout) as failures.

Co-Authored-By: AJ Steers <aj@airbyte.io>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
.github/workflows/prerelease-command.yml (1)

93-102: Nice addition for catching silent dispatch failures! One optional hardening: move the inline expressions to env vars.

GitHub's security hardening guide recommends that for inline scripts, the preferred approach is to set expression values to intermediate environment variables, rather than interpolating ${{ }} expressions directly into the shell script. While runId (a numeric value) and github.repository carry near-zero injection risk here, applying the env-var pattern consistently is good hygiene, wdyt?

🔒 Proposed hardening
     - name: Verify dispatched workflow succeeded
       run: |
-        CONCLUSION=$(gh run view ${{ steps.dispatch.outputs.runId }} --repo ${{ github.repository }} --json conclusion -q .conclusion)
+        CONCLUSION=$(gh run view "$RUN_ID" --repo "$REPO" --json conclusion -q .conclusion)
         echo "Dispatched workflow conclusion: $CONCLUSION"
         if [ "$CONCLUSION" != "success" ]; then
           echo "::error::Dispatched workflow concluded with: $CONCLUSION"
           exit 1
         fi
       env:
         GH_TOKEN: ${{ steps.get-app-token.outputs.token }}
+        RUN_ID: ${{ steps.dispatch.outputs.runId }}
+        REPO: ${{ github.repository }}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/prerelease-command.yml around lines 93 - 102, Move inline
GitHub Actions expressions into environment variables and reference those vars
in the shell block: define env entries for the dispatched run id (using
steps.dispatch.outputs.runId) and the repository (using github.repository) and
reuse the existing GH_TOKEN (steps.get-app-token.outputs.token), then update the
script to call gh run view using those env vars and assign the result to
CONCLUSION as before; ensure CONCLUSION, the echoed message, and the error/exit
logic remain unchanged but reference the new env variable names instead of
interpolated expressions.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In @.github/workflows/prerelease-command.yml:
- Around line 93-102: Move inline GitHub Actions expressions into environment
variables and reference those vars in the shell block: define env entries for
the dispatched run id (using steps.dispatch.outputs.runId) and the repository
(using github.repository) and reuse the existing GH_TOKEN
(steps.get-app-token.outputs.token), then update the script to call gh run view
using those env vars and assign the result to CONCLUSION as before; ensure
CONCLUSION, the echoed message, and the error/exit logic remain unchanged but
reference the new env variable names instead of interpolated expressions.

@devin-ai-integration
Copy link
Contributor

Re: CodeRabbit's suggestion to move ${{ }} expressions to env vars — runId is numeric and github.repository is a trusted context value, so there's no injection risk here. Leaving as-is to keep the step simple. Happy to apply if you prefer the pattern for consistency, AJ.


Devin session

@github-actions
Copy link

github-actions bot commented Feb 21, 2026

PyTest Results (Fast Tests Only, No Creds)

343 tests  ±0   343 ✅ ±0   5m 40s ⏱️ -1s
  1 suites ±0     0 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit 51167cc. ± Comparison against base commit fa52519.

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Feb 21, 2026

PyTest Results (Full)

413 tests  ±0   396 ✅ ±0   24m 44s ⏱️ -15s
  1 suites ±0    17 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit 51167cc. ± Comparison against base commit fa52519.

♻️ This comment has been updated with latest results.

Co-Authored-By: AJ Steers <aj@airbyte.io>
Copy link
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: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 4 additional findings.

Open in Devin Review

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In @.github/workflows/prerelease-command.yml:
- Around line 91-94: The dispatch step currently uses wait-for-completion and
wait-timeout-seconds but does not verify the triggered workflow's conclusion,
allowing silent success when the publish fails or times out; add a follow-up
verification step after the dispatch (referencing the dispatch step outputs like
steps.dispatch.outputs.runId or runUrlHtml) that runs gh run view --json
conclusion (or uses the prior action that checks conclusion) and explicitly
fails the job when the returned conclusion is not "success" so that
needs.build-and-publish.result reflects real failure and the failure comment
path executes.

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