Skip to content

plan: a parked run tells the terminal nothing actionable — announce where and how to answer it #52

Description

@Shashankss1205

What happens

With --approve, a run that parks awaiting a decision announces the request on stdout — but the announcement does not say how to answer it. The operator at the terminal (or the teammate the trace path gets pasted to) has to already know that grapharc approve <trace> exists, that --deny is the other half, and that the wait dies quietly after --approval-timeout (default 300s) with the round counted as unapproved.

Observed while driving a gated run: from the runner's side there is a long silence between the park and either a decision or the timeout, with no line saying what would end it, no countdown, and no pointer to the live view where the parked plan can actually be inspected (serve --live-root shows it grey with awaiting approval).

Why it matters

The approval gate is only as good as the odds a human actually answers it. Today those odds depend on tribal knowledge; the failure mode is a run that silently times out unapproved while its operator stares at a cursor — which then reads as a planner failure, not an unanswered question.

What to consider

  • At park time, print one actionable block: the fingerprint, the node list, answer with: grapharc approve <trace> (or --deny), the live-view URL when a live root is configured, and the deadline (waiting up to 300s).
  • On timeout, say that the timeout is what happened and repeat the command that would have answered it.
  • The Slack path already solves this with its status message; this is about parity for the plain CLI.

Acceptance criteria

A gated run's stdout names the approve command, the fingerprint and the deadline at park time; an unanswered run's final output attributes the stop to the approval timeout; existing approval tests pass unchanged.

Activity

  1. Shashankss1205 commented on Aug 8, 2026

    @Shashankss1205
    CollaboratorAuthor

    Fixed on main in #99.

    A parked run's announcement now names everything needed to answer it, without prior knowledge:

    awaiting approval — 3 nodes: gather, analyse, report
      fingerprint : 2ef3fc6dd5270c3b
      waiting     : up to 60s, then the round counts as unapproved
      approve     : grapharc approve runs
      refuse      : grapharc approve runs --deny
      look first  : grapharc approve runs --show
    

    That is the fingerprint, the node list, the deadline and what expiry means, and all three commands that end the wait — including --show, which is new (#46) and is the one a reviewer should reach for first.

    The formatting lives in planner/approval_file.describe_request, in plain text: that module is the headless half of the handshake, drivable by any process that can reach the directory, and it must not depend on the CLI's styling package. A test asserts it imports nothing from grapharc.cli. The CLI still prints the live-view URL above it, once, when a live root is reachable.

    On the timeout half — that already worked and I verified rather than assumed it:

    $ grapharc plan "…" --scripted --go --approve --approval-timeout 8
    stopped   : approval_timeout  (the admitted plan was not approved (timeout))
       round 2: admitted  nodes=3 executed=False
    $ echo $?
    1
    

    The stop is attributed to the timeout, the round is recorded as admitted-but-not-executed, and the exit code is non-zero, so a script cannot read an unanswered run as a success. A denied run behaves the same way.

    Not done: a live countdown. The announcement states the deadline once and the runner is otherwise silent until a decision or expiry. Happy to take that as a follow-up if the silence is still the problem in practice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions