Skip to content

fix(cli): point saved-result hint at real cost command (#538)#540

Merged
the-data-viking merged 1 commit into
mainfrom
fix/report-cost-hint
Jun 3, 2026
Merged

fix(cli): point saved-result hint at real cost command (#538)#540
the-data-viking merged 1 commit into
mainfrom
fix/report-cost-hint

Conversation

@claude-dataviking

Copy link
Copy Markdown
Contributor

Summary

synthpanel cost <result-id> errors (invalid choice: ... (choose from summary)) because cost only has the summary subcommand. The saved-result "Next:" block (printed after panel run --save) is where users look for follow-ups, so it now explicitly points at the two real cost surfaces instead of leaving a per-result cost <id> command implied:

  • synthpanel report <id> — full Markdown report (now annotated as including the cost rollup)
  • synthpanel cost summary — cost rollup across saved runs

This closes the CLI/docs inconsistency called out in the issue: the per-run cost rollup lives in report, and cross-run aggregation lives in cost summary. There is no per-result cost command.

Test

Added TestSavedResultHintCommands.test_hint_suggests_real_commands_not_per_result_cost in tests/test_results_discovery.py, asserting the hint surfaces report <id>, results show <id>, results list, and cost summary — and never the invalid cost <id> form.

Gates

  • ruff check . / ruff format --check .: pass
  • pytest tests/test_results_discovery.py: 10 passed

Closes #538

🤖 Generated with Claude Code

The saved-result "Next:" block is the canonical follow-up surface after
`panel run --save`. Users reaching for per-run cost reasonably try
`synthpanel cost <result-id>`, which errors because `cost` only accepts
the `summary` subcommand. There is no per-result `cost` command — the
per-run cost rollup lives in `synthpanel report <id>`, and cross-run
aggregation lives in `synthpanel cost summary`.

Surface both real paths in the hint and clarify that `report` already
carries the cost rollup, so nobody guesses the nonexistent `cost <id>`
form. Adds a regression test asserting the hint only suggests real
commands.

Closes #538

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying synthpanel with  Cloudflare Pages  Cloudflare Pages

Latest commit: ccbe043
Status: ✅  Deploy successful!
Preview URL: https://41bb16e0.synthpanel.pages.dev
Branch Preview URL: https://fix-report-cost-hint.synthpanel.pages.dev

View logs

@claude-dataviking claude-dataviking added the semver:skip Skip version bump on merge label Jun 3, 2026
@the-data-viking the-data-viking merged commit 4eadd2a into main Jun 3, 2026
19 checks passed
@the-data-viking the-data-viking deleted the fix/report-cost-hint branch June 3, 2026 23:10
the-data-viking added a commit that referenced this pull request Jun 3, 2026
Cuts the patch release containing the four bug fixes merged today (#540 cost
hint, #541 mcp-install path, #542 dry-run vision guard, #543 report synthesize
hint) plus the attachments docs (#535).

Pre-bumps __version__.py and re-renders the version artifacts (render_site.py,
render_site_markdown.py, render_server_card.py) so auto-tag.yml hits its
"nothing to commit" path and only tags v1.5.6 — its direct version-bump push
to main is currently rejected by branch protection (GH013), which is why
applying semver:patch to a regular fix PR (#543) failed to release. Filing
that pipeline issue separately.

Co-authored-by: Wesley Johnson <wesley@dataviking.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver:skip Skip version bump on merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

report 'Next' hint suggests 'synthpanel cost <result-id>' but cost only accepts the 'summary' subcommand

2 participants