Uh oh!
There was an error while loading. Please reload this page.
ui: remove the shared Banner method (no intro banner on any command) - #375
Conversation
Completes the banner removal started for the data commands (#370). The `tracebloc` + rule + subtitle block is gone from the last callers — `cluster info`, `resources`, `resources set` — and the shared `ui.Printer.Banner` method is deleted so nothing can reintroduce it. (`doctor` already dropped its banner in its own redesign.) Spacing: commands whose first line is a Section (`cluster info`) keep their leading blank from Section; the Stat/message-led paths (`resources` show, the `resources set` no-op / phantom-GPU notes) get an explicit Newline so every command still opens with exactly one blank line. Also dropped a now- redundant Newline in the `resources set` dry-run path (Section supplies it). Tests: drop the Banner unit-test call + its assertion; update the cluster-info test that asserted the "cluster diagnostics" subtitle; fix stale "banner" comments (incl. the ui package doc + a data-delete test). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
LukasWodka
commented
Jul 21, 2026
👋 Heads-up — Code review queue is at 31 / 30 Above the WIP limit. The team convention is to review existing PRs before opening new work. Open PRs currently in Code review (oldest first):
Pull from review before opening new work. (This is a nudge from the kanban WIP check, not a block.) |
Uh oh!
There was an error while loading. Please reload this page.
…gbot #375) After removing the intro banner, flag-driven interactive `resources set` (no --yes/--dry-run) opened with TWO blank lines: a Newline() immediately before PromptHint, which already self-leads with a newline. The dry-run path dropped its redundant Newline() (Section supplies one) but the confirm path kept the stacked pair, so the command no longer opened with a single blank line. Remove the redundant Newline() — PromptHint's own leading newline gives the one blank the PR's spacing contract promises. Adds TestSet_ConfirmOpensWithSingleBlank (drives the flag confirm path via runSet) to pin it. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
LukasWodka
commented
Jul 21, 2026
bugbot run |
Uh oh!
There was an error while loading. Please reload this page.
LukasWodka
commented
Jul 21, 2026
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
1 issue from previous review remains unresolved.
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 6afdd70. Configure here.
Uh oh!
There was an error while loading. Please reload this page.
…#375) The leading Newline() in runResourcesShow (before resolve, so a resolve-time redirect line also gets a blank) wasn't covered — every resources-show test drives renderResources directly, skipping it. Wire runResourcesShow to the resolveClusterTargetFn seam (matching the data commands) and add TestShow_OpensWithSingleBlank: it drives the outer function through a canned target and asserts it opens with exactly one blank — the mirror of TestSet_ConfirmOpensWithSingleBlank. Confirmed it fails if the Newline() is removed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
LukasWodka
commented
Jul 21, 2026
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 5c24c7b. Configure here.
Uh oh!
There was an error while loading. Please reload this page.
LukasWodka
commented
Jul 21, 2026
/fr-pass — verified live: no intro banner on |
Removing the intro Banner (#375) left `resources show` and `resources set` handling the leading blank differently, so the multi-client resolve-time redirect line got a blank on show but not on set (Bugbot "Missing lead blank on set path"). The naive fix — give set the same pre-resolve Newline() — would re-introduce the #375 double-blank (it stacks with the self-leading confirm PromptHint / dry-run Section). Standardize the spacing at the source instead of per-caller: - discoverRelease's multi-client redirect Infof now self-leads its own single blank, so every command that hits it gets exactly one leading blank — no per-command pre-resolve Newline() needed. - resources show moves its leading blank from before resolveClusterTarget into renderResources (before the first Stat), so it no longer stacks on the now-self-leading redirect in the multi-client case. - resources set keeps no command-level pre-resolve Newline() (preserves the #375 double-blank fix); its self-leading confirm/dry-run paths are unchanged. Tests: added a self-lead assertion to TestDiscoverRelease_ScanFindsSingleClient- Elsewhere; refreshed the stale comment in TestShow_OpensWithSingleBlank (the blank moved into renderResources). go build/test, gofmt -s, and go vet all pass. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…eview) The self-lead blank in discoverRelease's multi-client redirect fired wherever discoverRelease ran in each caller's output. For resolve-first commands (resources show/set, data list, seal) that's a clean leading blank. But cluster info, data ingest, and data delete all print output BEFORE resolving, so the self-lead landed mid-output — splitting cluster info's Kubeconfig section between the server and namespace Fields, and data ingest between "Connecting…" and its note (saadqbal review). Thread a leadRedirect bool through discoverRelease / resolveClusterTarget: true for resolve-first callers (redirect self-leads its one blank), false for output-first callers (note stays inline, no mid-output blank — restoring pre-PR spacing). resources set keeps NO pre-resolve Newline(), so the #375 confirm/dry-run double-blank fix is preserved. Add real MULTI-CLIENT tests for resources show and set that run through the actual resolve seam (loadClusterFn/newClientsetFn, not the resolveClusterTargetFn stub) so the redirect actually fires, asserting exactly one leading blank. Fix the overclaiming comment on TestShow_OpensWithSingleBlank (it only covers the single-client open). Drop the redundant "\n\n" disjunct in the clustertarget_test assertion. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…#468) * fix(#380): unify resolve-time leading blank across resources show/set Removing the intro Banner (#375) left `resources show` and `resources set` handling the leading blank differently, so the multi-client resolve-time redirect line got a blank on show but not on set (Bugbot "Missing lead blank on set path"). The naive fix — give set the same pre-resolve Newline() — would re-introduce the #375 double-blank (it stacks with the self-leading confirm PromptHint / dry-run Section). Standardize the spacing at the source instead of per-caller: - discoverRelease's multi-client redirect Infof now self-leads its own single blank, so every command that hits it gets exactly one leading blank — no per-command pre-resolve Newline() needed. - resources show moves its leading blank from before resolveClusterTarget into renderResources (before the first Stat), so it no longer stacks on the now-self-leading redirect in the multi-client case. - resources set keeps no command-level pre-resolve Newline() (preserves the #375 double-blank fix); its self-leading confirm/dry-run paths are unchanged. Tests: added a self-lead assertion to TestDiscoverRelease_ScanFindsSingleClient- Elsewhere; refreshed the stale comment in TestShow_OpensWithSingleBlank (the blank moved into renderResources). go build/test, gofmt -s, and go vet all pass. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * fix(#380): make redirect leading blank conditional per caller (#468 review) The self-lead blank in discoverRelease's multi-client redirect fired wherever discoverRelease ran in each caller's output. For resolve-first commands (resources show/set, data list, seal) that's a clean leading blank. But cluster info, data ingest, and data delete all print output BEFORE resolving, so the self-lead landed mid-output — splitting cluster info's Kubeconfig section between the server and namespace Fields, and data ingest between "Connecting…" and its note (saadqbal review). Thread a leadRedirect bool through discoverRelease / resolveClusterTarget: true for resolve-first callers (redirect self-leads its one blank), false for output-first callers (note stays inline, no mid-output blank — restoring pre-PR spacing). resources set keeps NO pre-resolve Newline(), so the #375 confirm/dry-run double-blank fix is preserved. Add real MULTI-CLIENT tests for resources show and set that run through the actual resolve seam (loadClusterFn/newClientsetFn, not the resolveClusterTargetFn stub) so the redirect actually fires, asserting exactly one leading blank. Fix the overclaiming comment on TestShow_OpensWithSingleBlank (it only covers the single-client open). Drop the redundant "\n\n" disjunct in the clustertarget_test assertion. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

What
The follow-up to #370: removes the intro banner from every remaining command and deletes the shared
ui.Printer.Bannermethod so it can't come back.The banner block —
— was a single shared method called by 7 commands. #370 removed it from the data commands; the
doctorredesign dropped it fromdoctor. This PR removes the last three callers (cluster info,resources,resources set) and deletes the method itself.Why now
Verified the follow-up is unblocked:
doctoralready de-bannered ondevelop; the resources redesign (#359) merged its new view but left the banner; PR #361 (which would have removed it) is closed; and the only open PR touching these areas (#369) is scoped todoctor.go— no collision.Spacing
Every command still opens with exactly one blank line:
cluster info— first line is aSection, which supplies its own leading blank → just remove the banner.resources(show) — first line is aStat(no leading newline) → replace the banner withNewline().resources set— the no-op and phantom-GPU messages are message-led → addNewline()to each; theSection/dry-run paths supply their own, so I also dropped a now-redundantNewline()in the dry-run path (it was double-blanking once the banner was gone).Verified live against a k3d env (
resources,cluster info,resources set --dry-runfor both the no-op and change paths) — all open with a single clean blank line.Changed
internal/ui/ui.go— deleteBanner; fix the package doc +Paracomment that referenced it.internal/cli/cluster.go,resources.go,resources_set.go— drop the banner calls (+ spacing as above).internal/ui/ui_test.go— drop theBannercall + its"tracebloc"assertion (the method no longer exists).internal/cli/cluster_info_test.go— the test asserted the"cluster diagnostics"subtitle; now asserts the Kubeconfig section (test-ctx) instead.internal/cli/data_delete_json_test.go— stale "banner" comment → "output".Test plan
go build ./...,go vet,gofmt— clean.go test ./...— all pass.Bannerremain (theinternal/submit"banner" hits are the ingestor's📊 INGESTION SUMMARYbanner — unrelated).🤖 Generated with Claude Code
Note
Low Risk
CLI presentation and test-only seams only; no auth, cluster mutation, or API behavior changes.
Overview
Removes the shared
ui.Printer.Bannerhelper and the last CLI callers (cluster info,resourcesshow,resources set), completing the de-banner work after earlier commands dropped it.Spacing:
resources showstarts withNewline()instead of a banner; no-op / phantom-GPU messages inresources setaddNewline()where needed; the confirm path drops an extraNewline()beforePromptHintso output does not double-blank; dry-run drops a redundantNewline()beforeSection.runResourcesShowuses theresolveClusterTargetFnseam for tests.Tests: Expectations move off banner subtitles (e.g. cluster info checks
test-ctx); new tests pin a single leading blank for show and set confirm after #375.Reviewed by Cursor Bugbot for commit 5c24c7b. Bugbot is set up for automated code reviews on this repo. Configure here.