Home Research

Galaxy workflow invocation failure reference

Reference for Galaxy workflow invocation states, messages, failure reasons, and invocation API surfaces.

Raw
Revised
2026-05-02
Rev
1
Sources
~/projects/repositories/galaxy/lib/galaxy/schema/invocation.py
~/projects/repositories/galaxy/lib/galaxy/workflow/run.py
~/projects/repositories/galaxy/lib/galaxy/workflow/modules.py
~/projects/repositories/galaxy/lib/galaxy/webapps/galaxy/api/workflows.py
component

Galaxy Workflow Invocation Failure Reference

This note describes workflow-level failure surfaces in Galaxy. It is separate from galaxy-tool-job-failure-reference because invocation state answers whether Galaxy could schedule and drive the workflow, while job state answers whether individual tool jobs succeeded.

Invocation Versus Job Failure

Important distinction:

  • Invocation state says whether Galaxy scheduled, cancelled, failed, or completed the workflow invocation.
  • Job state says whether jobs produced by invocation steps succeeded or failed.
  • Invocation messages explain scheduler/evaluation/cancellation problems.
  • Step states usually describe scheduling progress, not actual job success, unless a legacy serialization mode substitutes job state.

A robust workflow test reference should inspect both invocation APIs and job APIs.

Invocation States

Galaxy invocation states are defined in ~/projects/repositories/galaxy/lib/galaxy/schema/invocation.py and related model code.

StateMeaning
newNewly created invocation.
requires_materializationDeferred or undeferred inputs must materialize before scheduling can continue.
readyReady for another scheduler iteration.
scheduledWorkflow has been scheduled. Older clients may treat this as successful terminal state.
cancellingScheduler will cancel jobs and subworkflow invocations.
cancelledCancellation terminal state.
failedScheduler/evaluation/materialization failure terminal state.
completedNewer completion state after all jobs reach terminal states.

Version caveat: completed may not be uniformly available across all Galaxy/Planemo combinations. Planemo accounts for both scheduled and completed as success-like invocation states.

Invocation Message Reasons

Structured invocation messages are the main durable surface for workflow-level failures.

ReasonTypical meaning
dataset_failedDataset input or upstream dataset was failed/unusable.
collection_failedCollection was failed, incompletely populated, or unusable.
job_failedUpstream dependent job failed.
output_not_foundExpected step/subworkflow output could not be resolved.
expression_evaluation_failedWorkflow expression or condition evaluation failed.
when_not_booleanConditional when expression did not return a boolean.
unexpected_failureScheduler or evaluation failure without a more specific safe reason.
workflow_parameter_invalidWorkflow parameter validation failed.
step_input_deletedStep input dataset/collection was deleted.
history_deletedInvocation history was deleted, causing cancellation.
user_requestUser/API cancellation.
cancelled_on_reviewPause/review step rejected continuation.
workflow_output_not_foundWarning: declared workflow output was not found.

Message records can include affected workflow step id, dependent step id, job id, HDA/HDCA ids, output name, and nested workflow step index path. These fields matter more than free-text messages for reference-quality diagnosis.

Common Workflow-Level Failure Surfaces

SurfaceReference signal
Request-time validationAPI returns an error before useful invocation state exists.
Input materializationInvocation enters requires_materialization, then may fail with dataset_failed.
Conditional evaluationInvocation messages include expression_evaluation_failed or when_not_boolean.
Missing output graph edgeInvocation messages include output_not_found.
Deleted/purged inputsInvocation messages include step_input_deleted or dataset_failed.
Upstream job failureInvocation messages or summaries point to job_failed; job API has details.
Collection population failureInvocation messages include collection_failed; inspect HDCA and mapped jobs.
Pause/review rejectionCancellation reason cancelled_on_review.
User/history cancellationCancellation messages user_request or history_deleted.
Warning-only missing outputworkflow_output_not_found warning; may later become Planemo assertion failure.

API Surfaces

Useful invocation APIs from ~/projects/repositories/galaxy/lib/galaxy/webapps/galaxy/api/workflows.py:

APIUse
GET /api/invocations/{invocation_id}Invocation state, messages, inputs, outputs, and steps.
GET /api/invocations/{invocation_id}?step_details=trueRicher step detail, jobs, outputs, and output collections.
GET /api/invocations/steps/{step_id}Detail for one invocation step.
GET /api/invocations/{invocation_id}/steps/{step_id}Step detail scoped to invocation.
GET /api/invocations/{invocation_id}/jobs_summaryJob state summary across the invocation.
GET /api/invocations/{invocation_id}/step_jobs_summaryJob state summary per workflow invocation step.
GET /api/invocations/{invocation_id}/completionCompletion record, if available.
DELETE /api/invocations/{invocation_id}Cancel invocation.
PUT /api/invocations/{invocation_id}/steps/{step_id}Continue or cancel pause/review step.
GET /api/invocations/{invocation_id}/reportInvocation report surface.

Workflow aliases under /api/workflows/{workflow_id}/invocations/... also exist.

Planemo Caveats

Planemo polls invocation and job state, but its user-facing output may not expose all structured invocation messages. Treat Planemo terminal output as a summary; use raw invocation and job APIs when the failure class matters.

Likely noisy boundaries:

  • Planemo may show failed job details but omit structured invocation messages.
  • step_jobs_summary is useful in Galaxy but not necessarily surfaced directly by Planemo output.
  • Subworkflow paths can be represented in Galaxy message fields but may not be displayed by Planemo.
  • A workflow can be completed or scheduled while one or more jobs failed; job summaries must still be inspected.

Durable Reference Use

Use this note when a workflow run fails before or around job scheduling, when outputs are missing without an obvious tool stderr cause, or when Planemo only reports a generic invocation failure.

The goal is not to prescribe a single repair loop. The goal is to preserve which Galaxy API surface proves the failure mode so later Molds can decide whether the defect belongs to data-flow, template, concrete step implementation, workflow test assertions, or runtime environment.

Verification Gaps

Actual runs should verify:

  • Whether Planemo surfaces invocation messages for each reason.
  • Whether completed and /completion are populated in the target Galaxy used by tests.
  • How mapped collections and subworkflow failures appear in step_jobs_summary.
  • How warning-only workflow_output_not_found interacts with Planemo assertions.

Incoming References (3)