feat: add beta label to CLI output#324
Conversation
📝 WalkthroughWalkthroughAdds atomic filesystem-backed notice claiming in the config crate and introduces Storage beta messaging in catalog command help and runtime operations. ChangesStorage beta notice
Estimated code review effort: 3 (Moderate) | ~30 minutes Sequence Diagram(s)sequenceDiagram
participant CatalogCommand
participant BetaNotice
participant ConfigSession
participant Stderr
CatalogCommand->>BetaNotice: notify_once(STORAGE)
BetaNotice->>BetaNotice: check output mode and terminals
BetaNotice->>ConfigSession: claim_notice("storage")
ConfigSession-->>BetaNotice: claimed or already claimed
BetaNotice->>Stderr: write first-time beta notice
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 `@crates/tower-cmd/src/beta.rs`:
- Around line 28-34: Update the expected string in the
notice_omits_docs_sentence_without_a_url test to include the full
STORAGE.qualification text, including “its API contract and”, while preserving
the existing notice prefix and no-docs-sentence behavior.
🪄 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: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: d746f76d-f870-4b16-965d-fe75c3757993
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (7)
crates/config/Cargo.tomlcrates/config/src/lib.rscrates/config/src/session.rscrates/tower-cmd/src/beta.rscrates/tower-cmd/src/catalogs.rscrates/tower-cmd/src/lib.rscrates/tower-cmd/src/output.rs
| pub(crate) const STORAGE: BetaFeature = BetaFeature { | ||
| id: "storage-beta-v1", | ||
| name: "Tower Storage", | ||
| qualification: | ||
| "Core functionality is stable, but its API contract and CLI interface may evolve before general availability.", | ||
| docs_url: None, | ||
| }; |
There was a problem hiding this comment.
🎯 Functional Correctness | 🔴 Critical | ⚡ Quick win
Test assertion doesn't match the STORAGE.qualification text.
STORAGE.qualification reads "Core functionality is stable, but its API contract and CLI interface may evolve before general availability." (lines 31-32), but notice_omits_docs_sentence_without_a_url asserts the resulting notice equals a string that omits "API contract and " (line 79). notice() will actually produce "Tower Storage is in beta. Core functionality is stable, but its API contract and CLI interface may evolve before general availability.", so this assert_eq! will fail.
Align one side with the other:
🐛 Proposed fix (update the test to match the constant)
assert_eq!(
notice,
- "Tower Storage is in beta. Core functionality is stable, but its CLI interface may evolve before general availability."
+ "Tower Storage is in beta. Core functionality is stable, but its API contract and CLI interface may evolve before general availability."
);Also applies to: 74-82
🤖 Prompt for 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.
In `@crates/tower-cmd/src/beta.rs` around lines 28 - 34, Update the expected
string in the notice_omits_docs_sentence_without_a_url test to include the full
STORAGE.qualification text, including “its API contract and”, while preserving
the existing notice prefix and no-docs-sentence behavior.
e04b9d2 to
eb1144d
Compare
eb1144d to
fb8a0bd
Compare
Adding a resuable "beta feature" component that prints a beta label/warning when a beta feature is used.
Also, using the above mechanism for the Storage product commands ahead of the Preview/Beta launch.
e.g.

Summary by CodeRabbit
New Features
Bug Fixes
Tests