fix: restore iii-cloud binary registry entry#1444
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughAdded a new Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 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.
🧹 Nitpick comments (1)
engine/src/cli/registry.rs (1)
230-236: Add one more regression assertion for the update path (and optionally worker coexistence).
test_resolve_cloudis good forresolve_command, but a small extension to coverresolve_binary_for_update("cloud")would protect the update flow too.Suggested test hardening
#[test] fn test_resolve_cloud() { let (spec, sub) = resolve_command("cloud").unwrap(); assert_eq!(spec.name, "iii-cloud"); assert_eq!(spec.repo, "iii-hq/iii-cloud-cli"); assert!(sub.is_none()); + + let update_spec = resolve_binary_for_update("cloud").unwrap(); + assert_eq!(update_spec.name, "iii-cloud"); } + +#[test] +fn test_resolve_worker_still_present() { + let (spec, sub) = resolve_command("worker").unwrap(); + assert_eq!(spec.name, "iii-worker"); + assert!(sub.is_none()); +}🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@engine/src/cli/registry.rs` around lines 230 - 236, Extend the existing test_resolve_cloud by adding an assertion that calls resolve_binary_for_update("cloud") and verifies it returns the expected update binary (e.g., matching the same repo/name semantics as resolve_command) to cover the update path; locate the test function test_resolve_cloud and after the current assertions invoke resolve_binary_for_update("cloud") and assert the returned value equals the expected binary name/path (and optionally add a check that worker-related resolution still coexists if relevant).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@engine/src/cli/registry.rs`:
- Around line 230-236: Extend the existing test_resolve_cloud by adding an
assertion that calls resolve_binary_for_update("cloud") and verifies it returns
the expected update binary (e.g., matching the same repo/name semantics as
resolve_command) to cover the update path; locate the test function
test_resolve_cloud and after the current assertions invoke
resolve_binary_for_update("cloud") and assert the returned value equals the
expected binary name/path (and optionally add a check that worker-related
resolution still coexists if relevant).
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 216f2977-eba3-4fff-8aee-f82802ce2d92
📒 Files selected for processing (1)
engine/src/cli/registry.rs
The iii-cloud BinarySpec was accidentally replaced by iii-worker in cb54ced instead of being added alongside it, breaking `iii cloud`.
7ee327d to
7135e6d
Compare
Summary
iii-cloudBinarySpecwas accidentally replaced byiii-workerin feat: add managed worker sandbox with libkrun VM isolation #1402 (cb54ced3) instead of being added alongside itiii cloudwithUnknown command: 'cloud'sinceresolve_command("cloud")could no longer find a registry entryiii-cloudentry (repo:iii-hq/iii-cloud-cli, all 7 targets,tag_prefix: None) and its testTest plan
cargo test -p iii --lib -- registry— all 45 tests pass (including restoredtest_resolve_cloud)iii cloud --helpworks after installing the new binarySummary by CodeRabbit
cloudcommand to the CLI for accessing cloud service operations.cloudcommand resolves correctly.