Every gflow failure is an RFC 9457
Problem Details object. gflow ... --json prints it as {"status": "fail", "error": {...}},
and MCP tools return it as {"status": "error", "error": {...}}. Both carry the
same members, and the worker queue persists the same members for a queued task.
An MCP tool call that returns status: "error" (or failed, rate_limited,
invalid_tools, or a gflow_auth_status status other than authenticated) also has
isError: true on its result
(#1453,
#1464).
| Member | Always present | Meaning |
|---|---|---|
type |
yes | Stable URI per error class (tables below) |
title |
yes | Short human summary of the class |
detail |
no | What happened this time |
status |
no | The literal HTTP status of the failed call, when there was one |
remediation_hint |
no | What a person should do, in prose |
route |
no | Sanitized route name (never a full URL) |
class |
CLI --json, worker |
The concrete error class name (the worker's errors/unknown gives the qualified name, such as playwright._impl._errors.TimeoutError) |
exit_code |
CLI --json, worker |
The process exit code (table below) |
retryable |
yes | true when the identical request may simply be run again |
charged |
yes | Whether Flow may have billed this operation: no, maybe or yes |
next_action |
yes | What a caller should do (values below) |
operation_id |
no | The local job or media id, when one exists, so a follow-up can find it |
retry_after |
no | Seconds to wait, when Flow said so and next_action is retry_after |
completed_media_ids |
no | Media ids completed before a partial chain or a later per-command cap refusal |
quoted |
CreditCapExceededError |
Flow's pre-submit quote in credits, or null when unreadable |
max_credits |
CreditCapExceededError |
The caller's per-command credit ceiling |
charged, next_action, operation_id, retry_after and completed_media_ids were added in
#1201. They are additive: no
existing member changed.
CreditCapExceededError (exit 45) is gflow's refusal when Flow's pre-submit quote is missing
or over the requested cap. It reports quoted, max_credits, charged: no, and
next_action: fix_input; a cap refusal after completed chain/extend/movie work also carries
the completed media ids and reads charged: yes / reconcile.
Some --json commands report a failed run as a result document rather than an
error: video t2v/i2v/r2v when Flow reports the generation failed, both
video extend paths, and a partial video chain. Those documents carry charged and
next_action too (not retryable, type or class), because a billed clip is
exactly what these runs can leave behind
(#1159,
#1178): a failed generation reads
maybe / reconcile, and an extend or chain that completed at least one segment or
link reads yes / reconcile. A labs.google extend result carries the typed error's
charged and next_action
(#1416): extend input refused
before the submit reads no / fix_input, and a submitted segment that did not finish
reads maybe / reconcile, with that segment's media id as operation_id. When that
segment's poll fails with reauth or fix_input advice, the advice is kept, charged
stays maybe (yes once a segment finished) and retryable is false. A failed
flow.google.com extend reads maybe / reconcile.
no: the class proves nothing was submitted, or the operation is free (catalog, auth, uploads Flow refused, image generation, scene renders, balance reads).maybe: the failure can happen before or after a submit. Check the project before re-running a paid generation.yes: Flow made, and billed, the result. Re-running bills again.
| Value | Do this | retryable |
|---|---|---|
retry |
Run the same command again | true |
retry_after |
Run it again after a pause (quota or rate limit) | true |
wait |
Wait for a condition to clear (credits, another process holding the profile) | false |
reauth |
Run gflow auth login for the profile |
false |
fix_input |
Change the command, its inputs or the local setup | false |
reconcile |
Settle the outcome first: find the result in Flow (gflow data download <media_id> for a billed clip, gflow scene create --out-file for a scene) before re-running |
false |
none |
Nothing a caller can do will change the result | false |
retryable and next_action always agree: retryable is true exactly when
next_action is retry or retry_after. A raise site that overrides retryable
also moves next_action: one that turns the retry on reads retry, and one that
turns it off reads reconcile when the class says Flow may have billed, otherwise
none.
retry with charged: maybe. Six classes are raised both before and after a
submit and are retryable by default: TransportTimeoutError, NetworkError,
WafRejectionError, BrowserSessionClosedError, FlowAppError, FlowAgentUiError.
Every raise site gflow knows to come after a submit overrides them to reconcile
(retryable: false): the labs t2v/i2v/r2v and video extend poll timeouts, the
flow.google.com post-submit timeouts, a 5xx, timeout or connection reset on a billed
extend or upscale submit, a failed image submit on a transport that sends its own
reCAPTCHA token, the
agent-only composer's refusals, and a failed
download of a finished clip. So a retry that reaches you comes from a site gflow treats as before the
submit. On flow.google.com and on the labs (labs.google) composer, a site that is
provably before the submit click now also reads charged: no (see the overrides below); where maybe remains, gflow cannot prove
it: a scheduler that runs paid generations unattended should check the project before a
second paid attempt.
The tables give each type's default. A raise site can change any member: classes
built on the base constructor take charged=, next_action= and operation_id=
keywords, and the rest (RateLimitError, WireFormatError, BatchPartialError,
BatchIntegrityError, ChainPartialError, SyncPartialError,
UiModeUnavailableError) have the attribute set after construction. The overrides in
place today:
MediaDownloadErrorraised for a finished, billed clip (retryable: false, #941) readscharged: yes,next_action: reconcile, with the clip's media id asoperation_id. The same class raised by the free recovery (gflow data download, MCPgflow_download_media) keeps the defaultno/retry.- On flow.google.com, a finished clip whose signed URLs serve no MP4, or point outside
the allowed Google hosts, raises
WireFormatErrorwithcharged: yesand a remediation naminggflow data download <media_id>(#1159); the exit code is unchanged. - A
video extendpoll failure on a submitted segment whose action isreauthorfix_inputkeeps that action but readscharged: maybe(oryeswhen already billed) withretryable: false; any other poll failure readsmaybe/reconcile(#1416). - A labs video poll timing out after the submit reads
maybe/reconcile, with the media id asoperation_id. That covers both thet2v/i2v/r2vpoll (which used to surface as an unclassifiedUnexpectedError) and thevideo extendpoll. - A 5xx on a billed
video extendorimage upscalesubmit (NetworkError, #1260) readsmaybe/reconcile, and so does a timeout or connection reset while that submit is in flight (#1274), which used to exit 1 as anUnexpectedError. A browser closed while that submit is in flight reads the same (NetworkError, notBrowserSessionClosedError), because the request may already have reached Flow; a timeout before the submit is sent (the access-token fetch) is not reclassified. The request carries a single-use reCAPTCHA token, so it is sent once and never resent; check the project in Flow before running it again. - An image submit on a transport that sends the client's reCAPTCHA token (the HTTP
transports, not Flow's own page) failing with a 5xx, timeout or connection reset
(
NetworkError, #1275) readsmaybe/reconcile. The token is single-use, so the submit is sent once; check the project in Flow for the image before running it again. - A video Flow reports failed reads
maybe/reconcile, with its media id asoperation_id, on the worker queue as on the CLI. - A failed write of a generated asset to disk or a bucket (
ConfigurationError) readsmaybe/reconcile: the asset is in the Flow project. A scene render's write readsno/fix_input, because the render spends nothing. video chain: a typed error after at least one link completed keeps its class and readsyes/reconcile, with the last completed link's media id asoperation_idunless it already names the in-flight link. An untyped one is wrapped inChainPartialError.ChainPartialErrorreadsyesonly when it carries completed links, and lists them incompleted_media_ids.video extend --out-file: any failure while rendering billed segments (reading the scene back or the render itself) readsyes/reconcile. Its hint is the free re-render as a command that runs:gflow scene create --project <id> <clip refs> --out-file <path>.- A direct submit Flow refuses as
PUBLIC_ERROR_UNUSUAL_ACTIVITY(HTTP 200, an error frame and no generation record) is not billed, and is retried once from a new headless browser process. A second refusal is final:WafRejectionErrorwithcharged: no,retryable: falseandnext_action: wait; its hint names the cooldown in ACCOUNT_SAFETY and--browser-visibility headed(BROWSER_MODES). Any failure after a direct submit was sent, a redirect or HTTP 401/403 included, readsmaybe/reconcileand is never resent. A submit refused the same way on the UI path readsno/waittoo. image upscaleandvideo upscale: Flow refusing the upscale or export RPC asPUBLIC_ERROR_UNUSUAL_ACTIVITYisWafRejectionError(exit 10), never retryable, and itscharged/next_actiondepend on the scale. The scales measured to spend no credits (1080p, 720p and the 270p GIF for video, 2K for image; spike) readno/wait; 4K (a 4K video bills on click; 4K image billing is unmeasured and treated the same), and a refusal on thejwpdufstatus poll, which runs after Flow accepted the export, readmaybe/reconcile. Noretry_afteris given: no cooldown has been measured. Any other refusal of those RPCs staysWireFormatError(exit 7). A clip Flow has already rendered at the requested scale is served throughas29swith no export RPC; a refusal there follows the same scale rule, and any otheras29serror is ignored, because the page also usesas29sfor its own reads. Anas29srefusal during a fresh export ends it the same way, since it means the page itself is refused; there it reads the scale's refusal outcome even after Flow accepted the export (#1570). The direct path reads the same refusal on thejwpdufpoll and on theas29sread of the finished clip's URL, for a 1080p upscale, a text-to-video or an image-to-video, and stops at once withmaybe/reconcileinstead of waiting out its poll budget or reporting exit 7 (#1597). On the download-menu path, an upscale that times out after its click (TransportTimeoutError, exit 9), returns bytes that are not the file asked for, or has its export RPC refused for any other reason (WireFormatError, exit 7) follows the same scale rule: the free scales (1080p, 720p and 270p video, 2K image) readno/retry(re-running spends nothing), and 4K readsmaybe/reconcileand is never retryable (#1571, #1599). On the direct 1080p route a failure after the request was sent staysmaybe/reconcile, like every direct request.RelaunchFailed(exit 15,no/retry) is raised when the browser cannot start again, either for the retry after a refusal (its detail names the refusal) or for a request that reached no Flow endpoint and falls back to the UI path.- Sites that provably submitted nothing read
no: the flow.google.com extend editor guard (none), the/aboutlanding (reauth), and both balance-read failures. - On flow.google.com, a gflow error raised before the generation's submit click reads
charged: no(#1320): the settings pane, frame, reference and character attach, the prompt, and a submit button that is missing or stays disabled on the classic composer (missing only, on the agent-only composer), the source read and anchors ofvideo extend(including an Extend menu item Flow shows disabled: exit 35, #1334), the tile and menu steps ofimage upscaleandvideo upscalebefore the export click, and any failure of a reference upload (an upload is never a billed generation);next_actionkeeps the class default. A raw browser-driver timeout is not a gflow error and still readsmaybe. A submit the route guard aborts in the browser readsno/retry, unless a submit of the same run had already left the browser: that aborted stray never reached Flow, so it does not end the run, which returns its own clip or images or fails on its own outcome (#1529). A refusal whose abort fails readsmaybe/reconcileand, after the submit left, fails the run naming the run's clip or images. A request that left without the guard's judgment outranks any refusal and readsmaybe/reconcile. Every submit frame of a batched request is checked. A refusal of a request that is not a submit waits up to 1 s for the run's own submit before it readsno. A video failure after Flow accepted the submit readsmaybe/reconcileand names the accepted clip incompleted_media_ids; areauthorfix_inputaction is kept. Any other failure at or after the click keeps the class default. On the labs (labs.google) composer, a selector drift found while configuring settings, the prompt, navigation, video settings, the video editor mode or a character readsnoas well (#1336); a drift after the labs submit keepsmaybe.
operation_id is only set where an id already exists on the error.
Exit codes come from errors.EXIT_CODE_MAP; a class without its own entry inherits
its parent's, and an unmapped class exits 1. Exit 33 is not an error: gflow doctor
uses it for "findings present". Exit 80 is not an error either: see
Partial image results.
type |
Class | Exit | charged |
next_action |
|---|---|---|---|---|
https://gflow-cli.dev/errors/api-error |
FlowApiError |
1 | maybe |
none |
https://gflow-cli.dev/errors/batch-integrity |
BatchIntegrityError |
1 | no |
reconcile |
https://gflow-cli.dev/errors/batch-partial |
BatchPartialError |
1 | no |
reconcile |
https://gflow-cli.dev/errors/recaptcha-mint |
RecaptchaError |
1 | no |
none |
https://gflow-cli.dev/errors/task-cancelled |
TaskCancelledError |
1 | no |
none |
https://gflow-cli.dev/errors/task-not-found |
TaskNotFoundError |
1 | no |
fix_input |
https://gflow-cli.dev/errors/aisandbox-auth |
AisandboxAuthError |
3 | maybe |
reauth |
https://gflow-cli.dev/errors/auth-expired |
AuthExpiredError |
3 | maybe |
reauth |
https://gflow-cli.dev/errors/rate-limit |
RateLimitError |
4 | no |
retry_after |
https://gflow-cli.dev/errors/content-policy |
ContentPolicyError |
5 | maybe |
fix_input |
https://gflow-cli.dev/errors/media-download |
MediaDownloadError |
6 | no |
retry |
https://gflow-cli.dev/errors/network |
NetworkError |
6 | maybe |
retry |
https://gflow-cli.dev/errors/rpc-response-unavailable |
RpcResponseUnavailableError |
7 | maybe |
reconcile |
https://gflow-cli.dev/errors/wire-format |
WireFormatError |
7 | maybe |
reconcile |
https://gflow-cli.dev/errors/auth-missing |
AuthMissingError |
8 | no |
reauth |
https://gflow-cli.dev/errors/transport-timeout |
TransportTimeoutError |
9 | maybe |
retry |
https://gflow-cli.dev/errors/waf-rejection |
WafRejectionError |
10 | maybe |
retry |
https://gflow-cli.dev/errors/chain-manifest |
ChainManifestError |
11 | no |
fix_input |
https://gflow-cli.dev/errors/character-not-found |
CharacterNotFoundError |
11 | no |
fix_input |
https://gflow-cli.dev/errors/configuration |
ConfigurationError |
11 | no |
fix_input |
https://gflow-cli.dev/errors/profile-access |
ProfileAccessError |
11 | no |
fix_input |
https://gflow-cli.dev/errors/profile-engine-downgrade |
ProfileEngineDowngradeError |
11 | no |
fix_input |
https://gflow-cli.dev/errors/profile-locked |
ProfileLockedError |
11 | no |
wait |
https://gflow-cli.dev/errors/auth-login-timeout |
AuthLoginTimeoutError, IdentityRecheckPendingError |
12 | no |
reauth |
https://gflow-cli.dev/errors/security |
SecurityError |
13 | no |
fix_input |
https://gflow-cli.dev/errors/auth-browser-rejected |
AuthBrowserRejectedError |
14 | no |
reauth |
https://gflow-cli.dev/errors/browser-session-closed |
BrowserSessionClosedError |
15 | maybe |
retry |
https://gflow-cli.dev/errors/relaunch-failed |
RelaunchFailed |
15 | no |
retry |
https://gflow-cli.dev/errors/data-integrity |
DataIntegrityError |
16 | maybe |
fix_input |
https://gflow-cli.dev/errors/data-migration |
DataMigrationError |
16 | maybe |
fix_input |
https://gflow-cli.dev/errors/data-store |
DataStoreError |
16 | maybe |
fix_input |
https://gflow-cli.dev/errors/model-mode-incompatibility |
ModelModeIncompatibilityError |
17 | no |
fix_input |
https://gflow-cli.dev/errors/video-model-selection |
VideoModelSelectionError |
18 | no |
fix_input |
https://gflow-cli.dev/errors/scene-concat |
SceneConcatError |
19 | no |
fix_input |
https://gflow-cli.dev/errors/video-assembly |
VideoAssemblyError |
1 | no |
fix_input |
https://gflow-cli.dev/errors/frame-extraction |
FrameExtractionError |
20 | maybe |
fix_input |
https://gflow-cli.dev/errors/video-processing |
VideoProcessingError |
20 | no |
fix_input |
https://gflow-cli.dev/errors/chain-partial |
ChainPartialError |
21 | maybe |
reconcile |
https://gflow-cli.dev/errors/upscale-unavailable |
UpscaleUnavailableError |
22 | no |
none |
https://gflow-cli.dev/errors/server-cancel-unavailable |
ServerCancelUnavailableError |
22 | maybe |
reconcile |
https://gflow-cli.dev/errors/ui-selector-drift |
UiSelectorDriftError |
23 | maybe |
none |
https://gflow-cli.dev/errors/browser-engine-unavailable |
BrowserEngineUnavailableError |
24 | no |
fix_input |
https://gflow-cli.dev/errors/flow-agent-ui |
FlowAgentUiError |
25 | maybe |
retry |
https://gflow-cli.dev/errors/media-attribution |
MediaAttributionError |
26 | maybe |
reconcile |
https://gflow-cli.dev/errors/media-upload-rejected |
MediaUploadRejectedError |
27 | no |
fix_input |
https://gflow-cli.dev/errors/ui-mode-unavailable |
UiModeUnavailableError |
28 | no |
retry |
https://gflow-cli.dev/errors/mention-index-unavailable |
MentionIndexUnavailableError |
29 | no |
fix_input |
https://gflow-cli.dev/errors/queue-schema |
QueueSchemaError |
30 | no |
fix_input |
https://gflow-cli.dev/errors/flow-app |
FlowAppError |
31 | maybe |
retry |
https://gflow-cli.dev/errors/reference-not-found |
ReferenceNotFoundError |
32 | no |
fix_input |
https://gflow-cli.dev/errors/sync-partial |
SyncPartialError |
34 | no |
retry |
https://gflow-cli.dev/errors/extend-unavailable |
ExtendUnavailableError |
35 | no |
none |
https://gflow-cli.dev/errors/flow-host-migrated |
FlowHostMigratedError |
36 | no |
none |
https://gflow-cli.dev/errors/insufficient-credits |
InsufficientCreditsError |
37 | no |
wait |
https://gflow-cli.dev/errors/flow-account-chooser |
FlowAccountChooserError |
38 | no |
reauth |
https://gflow-cli.dev/errors/flow-access-unavailable |
FlowAccessUnavailableError |
39 | no |
none |
https://gflow-cli.dev/errors/credit-cap-exceeded |
CreditCapExceededError |
45 | no |
fix_input |
These are built by hand in the MCP server or the worker queue, and carry the same members. They have no exit code of their own.
type |
Built by | Exit | charged |
next_action |
|---|---|---|---|---|
https://gflow-cli.dev/errors/unknown |
MCP and worker, an unclassified failure (the message is never shared; the worker's detail is its SHA-256 and class names the exception class; after the submit the worker stores the job indeterminate and sets next_action: reconcile) |
— | maybe |
none |
https://gflow-cli.dev/errors/bad-parameter |
MCP, a tool argument it refuses; CLI --json, a usage error raised by the command (exits 2) |
— | no |
fix_input |
https://gflow-cli.dev/errors/confirmation-required |
MCP gflow_media_trash without confirm=true; CLI gflow media trash without --yes in non-interactive --json mode (exits 2, and its envelope omits next_action) |
— | no |
fix_input |
https://gflow-cli.dev/errors/no-profile |
MCP and CLI --json (exits 2), no profile, or its directory is missing |
— | no |
reauth |
https://gflow-cli.dev/errors/no-default-profile |
MCP and CLI --json (exits 2), several profiles and no default |
— | no |
fix_input |
https://gflow-cli.dev/errors/profile-marker-missing |
MCP gflow_auth_status |
— | no |
reauth |
https://gflow-cli.dev/errors/cookie-store-unreadable |
MCP gflow_auth_status |
— | no |
reauth |
https://gflow-cli.dev/errors/profile-unavailable |
MCP gflow_auth_status, the headless Chrome cookie read could not run (detail names the error class) |
— | no |
retry |
https://gflow-cli.dev/errors/verification-error |
MCP gflow_auth_status |
— | no |
retry |
https://gflow-cli.dev/errors/indeterminate-outcome |
Worker, interrupted after a submit was attempted, or MCP task row missing after execution | — | maybe |
reconcile |
https://gflow-cli.dev/errors/daemon-recovery |
Worker, interrupted before any submit | — | no |
retry |
https://gflow-cli.dev/errors/cancelled |
Worker queue, a task cancelled before any submit: gflow cancel / MCP tasks/cancel (state cancelled), or a server shutdown that stopped it |
— | no |
none |
An unclassified CLI failure (UnexpectedError) reads maybe / none too. Every
error gflow_auth_status returns reads charged: no, including its dead-session
auth-expired. A task that ended without a recorded error reads maybe / reconcile.
A task gflow cancel / tasks/cancel aborts after its submit is stored abandoned with
server-cancel-unavailable (maybe / reconcile); one a server shutdown stopped after
its submit is indeterminate-outcome, still reconcile, because Flow may have made it.
TaskCancelledError is what a worker raises when it finds its row aborted at the submit
gate; it never reaches the queue row, which stays cancelled. None of the worker's documents carries an
HTTP status: no HTTP call failed.
tests/test_problem_details_extensions.py fails when a type is missing here or a row
disagrees with what the code emits.
image t2i and image i2i with --count above 1 exit 80 when some of the images
were saved and the download of the next one failed
(#1477). It is a usable result, not
an error, so it has no type and is outside EXIT_CODE_MAP; exit 0 stays reserved for a
run that saved every image it asked for. Exit 80 is the same in both exit-code modes.
The saved files are printed (and listed under images with --json), the media ids that
were not saved are printed on stderr, and the --json result adds:
| Member | Meaning |
|---|---|
partial |
true |
requested |
Images asked for (--count) |
returned |
Images saved |
missing_media_ids |
Media ids Flow made that were not saved; they stay in the Flow project |
charged |
no: image generation spends no credits (see charged) |
next_action |
reconcile: fetch the missing ids from the Flow project instead of regenerating them, which would spend the daily image quota again |
retryable |
false |
The catalog records the run as succeeded: the missing images keep their asset rows with
no local file. When no image was saved the run stays a failure, and its stderr hint names
every media id. Over MCP the same run is a completed task carrying the same members
(see MCP.md). A script that accepts partial results can test for it:
gflow image t2i ... --count 2 || [ $? -eq 80 ].
In this release, gflow introduces a stable exit-code core. The default remains today's
legacy codes. Scripts opt in to the new codes by setting GFLOW_CLI_EXIT_CODES=2.
The core reserves low codes for broad outcomes:
0: success.1: general error.2: command-line usage or invalid input.3: authentication failure (expired session or missing profile).4: accepted and still running (reserved for asynchronous execution; emitted by nothing in this release).5–9: reserved.130: interrupted by signal (SIGINT).
Specific error causes move into the 40–63 range. Codes 10–39 remain unchanged.
| Legacy code | Core code (mode 2) | Error class / Meaning |
|---|---|---|
0 |
0 |
Success (unchanged) |
1 |
1 |
General or unclassified error (unchanged) |
2 |
2 |
CLI usage or input error (unchanged) |
3 |
3 |
AuthExpiredError (unchanged) |
4 |
40 |
RateLimitError (rate limit or quota hit) |
5 |
41 |
ContentPolicyError (content safety refusal) |
6 |
42 |
NetworkError (transient connection or HTTP failure) |
7 |
43 |
WireFormatError (unexpected response shape) |
8 |
3 |
AuthMissingError (missing credentials; merged with auth code 3) |
9 |
44 |
TransportTimeoutError (browser or network timeout) |
10–39 |
10–39 |
Specific causes (WAF, config, data store, credits, etc.; unchanged). 22 stays 22 for both UpscaleUnavailableError and ServerCancelUnavailableError (gflow cancel on a submitted job, #1198) |
45 |
45 |
CreditCapExceededError (Flow's pre-submit quote is unreadable or exceeds --max-credits, #1355; same code in both modes) |
130 |
130 |
Interrupted by user (unchanged) |
In the shared --json error envelope (and MCP queued failures), exit_code reports the
active process exit code (40 under mode 2, or 4 by default), and exit_code_legacy always
reports the legacy code. The process exit status follows the active mode on every command.
The change ships over three releases:
- This release: the legacy codes stay the default. Opt in with
GFLOW_CLI_EXIT_CODES=2, in the environment or in.env. - A later release: the stable core becomes the default.
GFLOW_CLI_EXIT_CODES=1restores the legacy codes and prints a one-line deprecation notice on stderr. - The release after that: the legacy codes are removed.