fix(proposals): audit before decided-move; close cli parity#475
Conversation
approve/reject/expire moved the proposal to decided/ and only then wrote the audit event, so a crash between the two produced a durable decision with no authoritative history. the log is authoritative: audit first, then move. a crash now leaves a pending proposal with its decision event — recoverable, and the approve retry path is already guarded by the existing-artifact check.
test_capabilities now asserts every kb.* method has a cli mirror (default foo-bar rule plus an explicit alias table), completing the jsonl + mcp checks. five methods had no mirror; they gain commands: propose-delete, source list, session list, session transcript, and session summarize. the session read commands mirror the jsonl surface's degraded-shape behaviour instead of erroring.
|
Warning Review limit reached
Next review available in: 40 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?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 reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. 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, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. 📝 WalkthroughWalkthroughThe CLI adds deletion proposal, source listing, and session inspection commands. Proposal approval, rejection, and expiration now audit before moving proposals to the decided state, with regression tests and CLI capability parity coverage. ChangesCLI proposal and introspection surfaces
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant CLI as vouch session summarize
participant Summarizer as session_split.summarize
participant Proposals as pending page proposals
CLI->>Summarizer: session_id and mode
Summarizer->>Proposals: create pending page proposals
Proposals-->>CLI: JSON result
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ 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 |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/vouch/cli.py`:
- Around line 2240-2250: Update the --mode option on session_summarize_cmd to
use click.Choice with the allowed values "auto", "split", and "mechanical",
preserving the existing default of "auto" and passing the validated mode to
session_split.summarize.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 919d070a-0039-4668-8961-5cecde95663f
📒 Files selected for processing (5)
src/vouch/cli.pysrc/vouch/proposals.pytests/test_audit.pytests/test_capabilities.pytests/test_cli.py
a typo like 'mechancial' silently fell through to the auto size gate; click.Choice rejects it at parse time. (coderabbit review)
two p0 integrity items from the roadmap (.superpowers/roadmap.md step 2):
full local gate green: pytest (non-embeddings), mypy, ruff.
Summary by CodeRabbit
New Features
propose-deletecommand with optional rationale and dry-run support.Bug Fixes
Tests