actions / runner

The Runner for GitHub Actions :rocket:
https://github.com/features/actions
MIT License
4.64k stars 892 forks source link

Using `force-cancel` returns a 500 error on a hanging workflow #3329

Open abelbraaksma opened 2 weeks ago

abelbraaksma commented 2 weeks ago

Describe the bug Calling the force-cancel endpoint using the following syntax, returns a 500 error (related to the recently implemented #1846).

To Reproduce

Have a workflow run that's hanging (if you need to repro this, there are currently two hanging runs in my org, see getaddify and ping me if you want me to try some things).

gh api --method POST repos/GetAddify/colonizer/actions/runs/9420995077/force-cancel

Response:

{
  "message": "Failed to cancel workflow run",
  "documentation_url": "https://docs.github.com/rest/actions/workflow-runs#force-cancel-a-workflow-run",
  "status": "500"
}

Expected behavior

Run is canceled. However, this does not happen.

Runner Version and Platform

Version of your runner? this in GitHub itself

OS of the machine running the runner? online in github.com

What's not working?

See response JSON above. It won't cancel the hanging run (even after 5 days).

Job Log Output

None. The runs appear as running, but didn't even start. It looks like this in the overview:

image

Runner and Worker's Diagnostic Logs

N/A