Skip to content

Workflow continues to PR creation after container execution failure #147

Description

@ekuris-redhat

Bug Description

When Podman is down, the Task Takeover workflow continues to the create_pr node instead of stopping at implement_task. This results in a misleading 422 error from GitHub ("'422 Unprocessable Entity' for url 'https://api.github.com/repos/forge-sdlc/forge/pulls'") because no code was actually produced.

Found in the Task Takeover workflow (task_takeover graph) while testing with ticket AISOS-2156.

Steps to Reproduce

  1. Stop Podman (or make it unavailable)
  2. Trigger a Task Takeover workflow (add forge:managed label to a Task issue)
  3. Workflow proceeds through triage, planning, and reaches implement_task
  4. Container execution fails silently (no code changes committed)
  5. Workflow continues to create_pr
  6. PR creation fails with 422: "'422 Unprocessable Entity' for url 'https://api.github.com/repos/forge-sdlc/forge/pulls'"
  7. Ticket gets escalated to forge:blocked

Expected Behavior

The workflow should detect that container execution produced no changes (or failed) at the implement_task node and either:

  • Retry the container execution
  • Escalate to forge:blocked immediately with a clear error message indicating container failure
  • Not proceed to create_pr when there are no commits on the branch

Actual Behavior

The workflow silently continues past implement_task to create_pr, which then fails with an unrelated GitHub 422 error. The root cause (Podman being down) is obscured by the PR creation error.

Observed Logs

forge.workflow.nodes.pr_creation - ERROR - PR creation failed for AISOS-2156:
Client error '422 Unprocessable Entity' for url 'https://api.github.com/repos/forge-sdlc/forge/pulls'

No error was logged at the implement_task stage despite Podman being unavailable.

Impact

  • Root cause is hidden behind a misleading error
  • Wastes a retry cycle (auto-retry at create_pr will fail again for the same reason)
  • Human debugging was required to discover that Podman was the actual issue

Metadata

Metadata

Assignees

Labels

area:executionAgent execution, containers, sandboxes, and runtime driversarea:workflowWorkflow graphs, orchestration, state, routing, and gatesbugSomething isn't workingwork in progress

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions