Skip to content

fix: Realign wt delete Human Copy to Stderr - #38

Merged
sahil-noon merged 3 commits into
mainfrom
260717-ohwb-delete-copy-stderr-realign
Jul 18, 2026
Merged

sahil-noon merged 3 commits into
mainfrom
260717-ohwb-delete-copy-stderr-realign

Conversation

@sahil-noon

Copy link
Copy Markdown
Collaborator

Meta

Change ID Type Confidence Plan Review
ohwb fix 4.8/5.0 15/15 tasks, 13/13 acceptance ✓ ✓ 1 cycle
Impact +/− Net
raw +392 / −68 +324
true +68 / −62 +6
└ impl +60 / −60 +0
└ tests +8 / −2 +6

excludes fab/, docs/ · generated by fab-kit v2.15.5

Pipeline: intake ✓ → apply ✓ → review ✓ → hydrate ✓ → ship → review-pr

Summary

wt delete violated toolkit principle No.2 (stdout is data, stderr is diagnostics) by printing all of its progress/summary copy to stdout. This closes the gap deferred from the toolkit-standards conformance audit (260709-6end) by moving every non-error human-copy call site in delete.go from fmt.Printf/fmt.Println to fmt.Fprintf/fmt.Fprintln(os.Stderr, ...), leaving wt delete's stdout empty on every path.

Changes

  • src/cmd/wt/delete.go — stdout → stderr at every non-error human-copy call site
  • Out of scope: shared interactive menu rendering (menu.go), no copy rewording or behavior changes
  • Tests — src/cmd/wt/delete_test.go (and integration guard)

@sahil-noon
sahil-noon marked this pull request as ready for review July 17, 2026 21:59
@sahil-noon
sahil-noon requested a review from Copilot July 17, 2026 21:59

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR realigns wt delete CLI output to follow the toolkit stream-discipline rule (“stdout is data, stderr is diagnostics”) by moving all non-error human-facing copy from stdout to stderr, and updates tests/docs to pin and document the new behavior.

Changes:

  • Redirected all non-error wt delete progress/summary/hint output in src/cmd/wt/delete.go from stdout to stderr (including the SIGINT framing newline).
  • Updated delete_test.go to assert empty stdout on a representative successful non-interactive delete path, and switched the two “No idle worktrees …” assertions to stderr.
  • Added/updated fab change artifacts and memory docs to record the closed [ohwb] gap and the new wt delete output contract.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/cmd/wt/delete.go Moves non-error human output from stdout to stderr across delete handlers.
src/cmd/wt/delete_test.go Updates assertions to reflect stderr output; adds explicit stdout-emptiness guard.
fab/changes/260717-ohwb-delete-copy-stderr-realign/plan.md Captures requirements/tasks/acceptance for the stream realignment.
fab/changes/260717-ohwb-delete-copy-stderr-realign/intake.md Introduces intake record describing the motivation and scope.
fab/changes/260717-ohwb-delete-copy-stderr-realign/.status.yaml Tracks fab change status/metrics for this work item.
fab/changes/260717-ohwb-delete-copy-stderr-realign/.history.jsonl Records fab stage transition history for the change.
docs/memory/wt-cli/toolkit-standards-conformance.md Updates principle №2 record to reflect [ohwb] gap closure.
docs/memory/wt-cli/idle-staleness-contract.md Notes that the stale empty-state message is now emitted on stderr.
docs/memory/wt-cli/create-output-phases.md Extends stream-discipline documentation to cover full wt delete realignment.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

sahil87 added 3 commits July 18, 2026 10:34
Move all non-error progress/summary output in delete.go to stderr,
closing the toolkit principle No.2 gap deferred from 260709-6end.
Wording, colors, and framing are unchanged — only the stream flips.
stdout is now empty on every wt delete path.
@sahil87
sahil87 force-pushed the 260717-ohwb-delete-copy-stderr-realign branch from 6124f1c to 3f38cb7 Compare July 18, 2026 05:04
@sahil-noon
sahil-noon merged commit 7d311e1 into main Jul 18, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants