Skip to content

Plan and apply output

reflow plan previews which flows will run, reuse retained evidence, or block—without executing application steps. reflow apply runs that plan with a live dependency tree, Watch live: dashboard link, timing breakdown, and optional OTLP tracing.

In an interactive terminal (at least 24 columns wide), reflow apply draws the dependency tree on stderr and redraws it in place while started, done, and failed lines scroll above:

apply 45 flows · 4 running · 19 waiting · 21 done · 1 failed · 10:26 · about 11:30 left
gram-seed-state ✔ 0:10
├─ ✔ 18 passed slowest stage9-org-settings 3:55
├─ ✔ 2 reused login-smoke, sign-up-page
├─ ✖ e2e-role failed at step 5/5 Delete the role 1:52
│ expected the row "qa-role-7f3a" to be gone; it was still listed after 5 s
├─ ● mcp-server-detail 1:21 of ~2:31
│ ▮▮▮▯▯ 3/5 Open the tools tab 0:12
└─ ◌ 19 waiting: parallelism 4 next stage9-server-tabs, stage9-environments, …
  • Passed and reused flows fold into summary lines (and N more when truncated); prerequisite flows stay expanded while dependents are active.
  • Running flows show current step progress, step elapsed time, total elapsed time, and last passing duration (of ~2:31) when available.
  • Waiting flows appear beneath their first needs dependency and state what they wait on (dependency, --parallelism, or device capacity). See Matrix runs and parallel execution for matrix: fan-out and --parallelism scheduling.
  • Failed and skipped flows show the failing step and first error line, or the skip reason (if:/unless: or failed/skipped dependency). Condition skips never fail the apply.
  • ETA (about 11:30 left) packs waiting flows’ prior passing durations across free workers (or shows at this pace once at least one flow finishes).

Under CI, TERM=dumb, or a pipe, redraw is disabled and stderr emits line-oriented events plus a once-per-minute summary (--log-level error prints failures only):

plan: 43 to run, 2 to reuse; parallelism 4
admitted apply 7c1e42d0-1111-4222-8333-444444444444 parallelism 4
Watch live: https://app.reflow.io/acme/executions/apply/7c1e42d0-1111-4222-8333-444444444444
started gram-seed-state
done gram-seed-state 0:10 slowest step Create the organization 0:04
started catalog-add-crud
apply 3/45 done · 0 failed · 4 running · 38 waiting · 1:00 · about 21:30 left

At admission, both terminal and pipe modes print admitted apply <request-key> and a Watch live: link to the apply’s page in the Reflow app (or reflow watch --request <request-key> when no app page is available).

When every selected flow is reused, apply starts no run, prints nothing to run: all N flows were reused from earlier runs (apply <request-key>), and omits Watch live:. Its app page and reflow watch --request <request-key> still list the reused flows with nothing ran in the header.

Attach read-only to an active apply from any other terminal—watch never cancels runs, writes result files, or starts/stops the device service (Ctrl-C detaches cleanly). Pass --titles to show flow titles instead of slugs:

Terminal window
reflow watch # the single in-flight apply on this device
reflow watch --request <request-key> # a specific apply by admission key
reflow watch --result-file /tmp/apply.json # follow the apply writing this result file
reflow watch --suite <output-dir> # follow a reflow coverage suite run

With --result-file, watch prints the apply’s final report and mirrors its exit code. Otherwise it exits 0 when every flow passed, was reused, or was skipped by a condition. --suite adds suite label, repeat, shard, and apply counters above the tree.

A flow reuses retained evidence when its target epoch, inputs, plugin pins, dependencies, and covered source match a prior passing run. Otherwise reflow plan prints the exact trigger:

TriggerPlan behavior and printed reason
Flow, covered source, bindings, inputs, or config changedRuns invalidated step and downstream steps (or whole flow for Browser/cleanup/service).
reflow init --upgrade updated a plugin pinReruns flows using that plugin and names the changed pins.
Browser flow with any step invalidatedReplays from step 1 (Reconstruct stateful session), unless continuing on --hold.
Flow with cleanup stepsRuns whole (The flow has cleanup steps, so it runs whole: its last cleanup undid what a reused step made).
Flow starting a LocalBash serviceRuns whole (The flow starts a service, so it runs whole: what a reused step started ended with its run).
Prior failure or timeoutReruns automatically without reflow taint (Previous execution failed, naming any timeout limit: statement, step, flow, 31m default, or 30m provider-call cap).
Unknown completion (lost reply, dropped worker, cancelled mid-call, or errored mutating command like db.execute)Blocked until you inspect the run and clear it explicitly with reflow taint (input edits alone never override an unknown completion).

Every apply report ends with a Where the time went breakdown ranking non-flow phases and the slowest executed flows and steps:

Where the time went (wall clock 23:24)
startup 3.8s
tag selection 3.4s
plan 3.9s
device service 3.8s
prepare passes 3.7s
source fetch ×11 0.9s
admission 11.4s
prepare passes ×2 6.1s
admission request 4.2s
reused-run reads ×11 0.9s
flows 23:00
cleanup 2.6s
comparing snapshots 6.0s
Slowest flows
stage9-observe 6:08 slowest step Open the traces tab 2:10

Sub-lines under a phase can overlap, so rank them rather than summing them (other is unmeasured wall clock). For slow planning, run with --log-level debug (or set REFLOW_LOG_LEVEL=debug for local MCP) to emit a plan_timings event on stderr without altering stdout:

Terminal window
reflow plan smoke checkout --log-level debug

The first command after an upgrade or device-service start is slower than warm runs; compare warm runs against the same flows, target, and plugin lock, and never repeat an apply solely to collect timings.

Tracing is off by default and enabled per command via environment variables:

VariableEffect
REFLOW_TRACE_FILE=/path/trace.jsonlAppend one OTLP/JSON span per line.
OTEL_EXPORTER_OTLP_ENDPOINT or OTEL_EXPORTER_OTLP_TRACES_ENDPOINTPost spans to an OTLP/HTTP collector when the command finishes.
OTEL_EXPORTER_OTLP_HEADERSCustom collector headers (e.g. authorization).
REFLOW_DEBUG=perfPrint a span tree and top self-time contributors to stderr.

A single trace spans the CLI, device service, and plugin workers—naming phases, flows, steps, plugin calls, and API requests while never recording tokens, bodies, query values, or error text. Review trace files before sharing.