Software factory / Runs
Stop a run
A run is wrong, for example it reads the wrong pull request, or it costs too much. Stop it now, and do not wait for its time limit.
2 min read
You need:
- Write access to the repository.
1. Open the page of the run
In the Factory panel, click Log on the row of the run. You can also open the run from All runs.
2. Click Stop run
Click Stop run under the name of the agent. The button is there while the run is queued or running.

3. Read the status
The run shows Cancelled, and its reason says who stopped it, for example Stopped by @maya.
A run that ended meanwhile is not stopped. The line under the button says why.
Done
The run stopped before its time limit. To start it again, click Retry under its row in the Factory panel. See Retry a run.
A run that stops by itself
A run on a pull request also stops by itself. A few seconds after the pull request merges or closes, the forge stops each of its runs that is queued or running.
The run shows Cancelled, with the reason The pull request was merged. or The pull request was closed.
A reopen of the pull request does not start the run again. Push, or use its re-run button.
From src, MCP or REST
src factory cancel <run id>
- The MCP tool is
cancel_factory_run, withowner,repoandid. - The REST route is
POST /api/v1/repos/{owner}/{repo}/factory/runs/{id}/cancel. It answerscancelledwith the run id, orskippedand the reason.