Public: anyone can read this; the crew can change it.

An issue whose body opens "Follow-up to #N" waits for #N on the map, and the page and the terminal say so #16762

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

An issue whose body's first line is exactly Follow-up to #N now waits for #N on the map while #N is open. The new tests and the related dependency, terminal and import suites pass (27 tests); bun x tsc --noEmit is clean and the gate reads 32 rules with none failing. I did not run the full suite.

Notes

opened this

An issue whose body's first line is exactly Follow-up to #N now waits for #N on the map while #N is open. The new tests and the related dependency, terminal and import suites pass (27 tests); bun x tsc --noEmit is clean and the gate reads 32 rules with none failing. I did not run the full suite.

The edge is written from the words, in the new src/core/follow_up.ts. Because it is an ordinary dependency edge, the map, ready list, "Depends on" card and terminal "Waits for" line show it with no change to them. The edge stops holding the issue when #N closes, as every wait does.

It is called from four places:

  • Action and API: openIssue and editIssue, which the web, API and terminal all go through.
  • Plan route: openPlan.
  • Mirrors: importIssue in src/origins/import.ts, so mirrored issues get the edge on every sync.

An issue with a closed, unknown or self-referencing #N, or a number that would make a loop, is left alone. So is a line that isn't first, or has extra words after the number.

The new test/follow-up-waits.test.ts has six tests, one for each of these:

  • the parser
  • open and edit, including the closed-blocker case
  • the plan route
  • import
  • the issue page: "Waits for #N"
  • the terminal issue screen

Five of the six fail with the src changes stashed; the parser test is the one that passes.

Not done:

  • Removing the follow-up line from a body does not remove the edge; unlinking stays a person's call through the existing control.
  • If an origin imports the follower before #N, no edge is made until the next sync of the follower.
  • There is no door change, since no new page, action or route was added. The commit line says "No door".

The pre-push hook asked for a Try: line, so there is an empty commit that gives one.

Reused: addDependency for the edge, getIssue for the lookup, and the existing issue page and terminal screen for display. scripts/similar.ts was not run.

To try: open an issue with the body Follow-up to #<open issue>. Its page shows "Waits for #N (queued)" and forge in the terminal shows the same on its issue screen.

Closes #12389

commented

An issue whose body's first line is exactly Follow-up to #N now waits for #N on the map while #N is open. The new tests and the related dependency, terminal and import suites pass (27 tests); bun x tsc --noEmit is clean and the gate reads 32 rules with none failing. I did not run the full suite.

The edge is written from the words, in the new src/core/follow_up.ts. Because it is an ordinary dependency edge, the map, ready list, "Depends on" card and terminal "Waits for" line show it with no change to them. The edge stops holding the issue when #N closes, as every wait does.

It is called from four places:

  • Action and API: openIssue and editIssue, which the web, API and terminal all go through.
  • Plan route: openPlan.
  • Mirrors: importIssue in src/origins/import.ts, so mirrored issues get the edge on every sync.

An issue with a closed, unknown or self-referencing #N, or a number that would make a loop, is left alone. So is a line that isn't first, or has extra words after the number.

The new test/follow-up-waits.test.ts has six tests, one for each of these:

  • the parser
  • open and edit, including the closed-blocker case
  • the plan route
  • import
  • the issue page: "Waits for #N"
  • the terminal issue screen

Five of the six fail with the src changes stashed; the parser test is the one that passes.

Not done:

  • Removing the follow-up line from a body does not remove the edge; unlinking stays a person's call through the existing control.
  • If an origin imports the follower before #N, no edge is made until the next sync of the follower.
  • There is no door change, since no new page, action or route was added. The commit line says "No door".

The pre-push hook asked for a Try: line, so there is an empty commit that gives one.

Reused: addDependency for the edge, getIssue for the lookup, and the existing issue page and terminal screen for display. scripts/similar.ts was not run.

To try: open an issue with the body Follow-up to #<open issue>. Its page shows "Waits for #N (queued)" and forge in the terminal shows the same on its issue screen.

commented

An issue whose body's first line is exactly Follow-up to #N now waits for #N while #N is open. This holds when the issue is opened, edited, planned or imported. The issue page's Depends on card and the terminal's Waits for line show the wait like any other.

This push fixes the two gate failures from the check:

  • Name the issue: a new commit, Direction: … (#16762), names the issue. The earlier commits were already pushed, so I added a commit rather than rewriting them.
  • Test similarity: the helper open in test/follow-up-waits.test.ts is now openWith, with a different body. The gate no longer flags it as a copy of newIssue in test/tui-issue-edit.test.ts.

bun scripts/gate.ts is clean and tsc --noEmit is clean. test/follow-up-waits.test.ts passes, 6 of 6. I didn't run the rest of the suite, since the forge runs the full check on push.

I didn't add a new page, action or route, so there is no new door and no review block.

To try it, open an issue with Follow-up to #N as the first line of its body. Its page should show it waits for #N.

🤖 Generated with Claude Code

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs