fix(cli): route all session subcommands through one Typer group#449
fix(cli): route all session subcommands through one Typer group#449Prateeks16 wants to merge 1 commit into
Conversation
`session_app` was defined three times in cli/main.py: an empty group near the app definition, the real group carrying watch/replay/list/export/score, and a third reassignment near the rollback/prune commands. Each was added to `app` under the name "session", so the command group resolved to the last (partial) one and `agentwatch session export` / `session list` failed with "No such command 'export'". Remove the empty duplicate and the trailing reassignment so rollback/prune attach to the same single `session_app` as the rest. Also fix test_export_invalid_format, which read result.stderr (not separately captured by this Click version) — use result.output. Fixes the 10 failing tests in test_cli_api_key.py and test_cli_export.py.
|
Warning Review limit reached
More reviews will be available in 35 minutes and 38 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan refill rate. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, the refill rate gradually slows as usage increases. The highest same-day bursts are limited more strictly. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🧪 PR Test Results
Python 3.12 · commit 4ff98fc |
|
@sreerevanth could we prioritize merging this one? It fixes a bug already on None of those PRs touch that code; they just inherit the breakage. Merging this turns their CI green on rebase with no further changes. This PR is self-contained (2 files) and green on its own. |
Problem
agentwatch session exportandsession listfail onmainwithNo such command 'export', breaking 10 tests intest_cli_api_key.pyandtest_cli_export.py.Root cause:
cli/main.pydefinessession_appthree times and adds each toappunder the name"session":watch/replay/list/export/score,rollback/prunecommands.The group resolves to the last (partial) one, so the export/list subcommands aren't found.
Fix
rollback/pruneattach to the same singlesession_appas everything else.test_export_invalid_formatreadresult.stderr(not separately captured by this Click version) → useresult.output.Verification
This is the shared
mainbreakage currently failing CI on every open PR cut frommain(#411, #443, #445). Merging this unblocks all of them — they go green on rebase with no further changes.