Repository navigation
fix(actions): keep runner_name after ephemeral runner removal - #39725
Merged
silverwind merged 13 commits intoNov 13, 2026
Merged
silverwind merged 13 commits into
silverwind merged 13 commits into
Conversation
An ephemeral runner is deleted as soon as its task is done, before the completed workflow_job webhook is built, so the job was reported without runner_name as if it had never been assigned. Store the runner name on the task when the job is claimed and read it from there. Assisted-by: Claude Code:claude-opus-5-5
Assisted-by: Claude Code:claude-opus-5-5
Assisted-by: Claude Code:claude-opus-5-5
… tasks Assisted-by: Claude Code:claude-opus-5-5
kirmanak
marked this pull request as ready for review
October 10, 2026 12:26
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
The fallback lookup error is discarded, allowing transient database failures to produce an empty runner_name.
0 open findings
What changed in this PR
Preserves runner names for completed Actions jobs after ephemeral runners are removed.
Changes:
- Stores runner names when tasks are claimed.
- Adds migration and legacy fallback lookup.
- Adds conversion, unit, and integration tests.
| File | Summary |
|---|---|
tests/integration/actions_job_test.go |
Tests completed jobs after runner removal. |
services/convert/convert.go |
Uses stored or legacy runner names. |
services/convert/action_test.go |
Tests runner-name conversion. |
models/actions/task.go |
Persists runner names on tasks. |
models/actions/task_test.go |
Tests runner-name persistence. |
modelmigration/v29/v358.go |
Adds the runner-name database column. |
modelmigration/migrations.go |
Registers migration 358. |
🧠 Review effort: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Renumber the action_task runner_name migration from 358 to 359, since main took 358 for the remember-me token hash migration.
Copy the runner name into existing action_task rows during the migration, so older tasks keep it after the runner row is purged. Make the column NOT NULL DEFAULT '' and have the integration test purge the ephemeral runner before checking the reported name.
Renumber the action_task runner_name migration from 359 to 361, since main took 359 and 360.
Renumber the action_task runner_name migration from 361 to 362, since main took 361. Assisted-by: Claude Code:claude-opus-5-5
…-runner-name-in-completed-workflow # Conflicts: # modelmigration/migrations.go # modelmigration/v29/v362.go # services/convert/convert.go
Every claimed task stores the runner name and the migration backfills existing ones, so converting jobs no longer needs to load runners. Assisted-by: Claude Code:claude-opus-5-5
Member
|
Pushed 507c75b with small cleanups:
Written by Claude. |
silverwind
approved these changes
Oct 18, 2026
…-runner-name-in-completed-workflow Renumber the action_task runner_name migration from 363 to 365, since main took 363 and 364. Assisted-by: Claude Code:claude-opus-5-5
wxiaoguang
approved these changes
Nov 12, 2026
…n-completed-workflow * origin/main: (139 commits) refactor: use ExclusiveFetch to simplify AbortController (go-gitea#40312) fix: handle task list items checked with uppercase X (go-gitea#40334) test: add e2e tests for comments, file tree, actions and branch protection (go-gitea#40313) enhance(lfs): report status and body on non-JSON LFS error responses (go-gitea#40331) feat(ssh)!: remove SSH DSA key support (go-gitea#40332) refactor(git): parse git stdout correctly (go-gitea#40326) [skip ci] Updated translations via Crowdin fix(repo): rank exact repository name matches first (go-gitea#39038) fix(web): avoid compare output route collisions (go-gitea#40307) refactor: clean up error system (go-gitea#40328) fix(markup): keep list items on separate lines in quote replies (go-gitea#40329) fix(repo): require the unit in AccessibleRepositoryCondition (go-gitea#40059) fix(ui): consistent spacing between labels (go-gitea#40261) [skip ci] Updated translations via Crowdin test: fix the login tab order e2e test in macOS WebKit (go-gitea#40316) fix(api): keep webhook settings that are omitted in an edit request (go-gitea#40282) fix(indexer): reindex issues when their projects change (go-gitea#40299) chore(deps): update go toolchain directive to v1.27.4 (go-gitea#40315) chore(css): remove dead CSS (go-gitea#40314) fix(packages): generic package deletion ignores terraform state lock and latest version (go-gitea#40302) ... Assisted-by: Claude Code:claude-opus-5-5 # Conflicts: # modelmigration/migrations.go # modelmigration/v29/v365.go # modelmigration/v29/v365_test.go
silverwind
enabled auto-merge
November 12, 2026 18:29
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.
Jobs that ran on ephemeral runners lose
runner_namein theworkflow_jobcompleted webhook and the jobs API, because the runner row is deleted when the task finishes. GitHub keeps bothrunner_idandrunner_name, and GARM ignores completed jobs without a name, holding the runner slot until its periodic cleanup.The name is now stored on the task when claimed, and a migration backfills tasks whose runner row still exists.