Skip to content

pikaci: fast-path staged Linux runs on single-host Incus#726

Closed
justinmoon wants to merge 1 commit intomasterfrom
wt-d1a8796d
Closed

pikaci: fast-path staged Linux runs on single-host Incus#726
justinmoon wants to merge 1 commit intomasterfrom
wt-d1a8796d

Conversation

@justinmoon
Copy link
Copy Markdown
Collaborator

@justinmoon justinmoon commented Mar 20, 2026

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 20, 2026

Warning

Rate limit exceeded

@justinmoon has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 9 minutes and 50 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b055a996-d1a2-4816-aceb-426022395e61

📥 Commits

Reviewing files that changed from the base of the PR and between 027b2aa and 4cca428.

⛔ Files ignored due to path filters (2)
  • nix/ci/pika-core-workspace/Cargo.lock is excluded by !**/*.lock
  • nix/ci/rmp-workspace/Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (12)
  • crates/pikaci/src/executor.rs
  • crates/pikaci/src/main.rs
  • crates/pikaci/src/model.rs
  • crates/pikaci/src/run.rs
  • crates/pikahut/tests/guardrails.rs
  • docs/incus-migration-plan.md
  • flake.nix
  • nix/ci/linux-rust.nix
  • nix/ci/rmp-workspace/rmp-template/desktop/iced/Cargo.toml
  • nix/ci/rmp-workspace/rmp-template/rust/Cargo.toml
  • nix/incus/pikaci-image.nix
  • scripts/check-cargo-machete
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch wt-d1a8796d
📝 Coding Plan
  • Generate coding plan for human review comments

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

View 6 additional findings in Devin Review.

Open in Devin Review

"" | "auto" => None,
"incus" => Some(RemoteLinuxVmBackend::Incus),
"microvm" => Some(RemoteLinuxVmBackend::Microvm),
_ => None,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 forced_remote_linux_vm_backend silently ignores unknown env var values instead of failing

When an operator sets PIKACI_REMOTE_LINUX_VM_BACKEND to an unrecognized value (e.g., a typo like "Incus" or "mcrovm"), the _ => None catch-all silently falls through to auto-detection logic rather than returning an error. This is inconsistent with the analogous remote_linux_vm_incus_mode() at crates/pikaci/src/executor.rs:2264-2276 which explicitly bails on unrecognized values. Since the migration plan at docs/incus-migration-plan.md:862 describes this env var as the "rollback escape hatch," silently ignoring a typo could cause an operator to believe they've forced microvm rollback when auto-detection is actually selecting Incus.

Prompt for agents
In crates/pikaci/src/model.rs, the forced_remote_linux_vm_backend function at line 569-578 has a catch-all _ => None arm that silently ignores unrecognized PIKACI_REMOTE_LINUX_VM_BACKEND values. Change the _ => None arm to log a warning or return an error (bail!/panic) to match the fail-fast pattern used in remote_linux_vm_incus_mode() at crates/pikaci/src/executor.rs:2264-2276. For example, change it to something like:

_ => {
    eprintln!("warning: unsupported {} value {:?} (expected 'incus', 'microvm', 'auto', or empty); falling through to auto-detection", REMOTE_LINUX_VM_BACKEND_ENV, raw);
    None
}

Or, for a stricter approach matching the existing pattern, make the function return anyhow::Result<Option<RemoteLinuxVmBackend>> and bail on unknown values.
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@justinmoon justinmoon closed this Mar 20, 2026
auto-merge was automatically disabled March 20, 2026 14:52

Pull request was closed

@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 14:52
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 21:20
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 21:21
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 21:49
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 21:53
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 21:58
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 21:59
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:04
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:04
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:09
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:10
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:15
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:20
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:21
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:26
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:26
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:31
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:32
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:37
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:38
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:42
@justinmoon justinmoon restored the wt-d1a8796d branch March 20, 2026 22:43
@justinmoon justinmoon deleted the wt-d1a8796d branch March 20, 2026 22:47
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 18:35
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 18:36
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 18:42
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 18:46
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 18:47
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 18:52
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 18:53
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 18:57
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 18:59
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:02
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:04
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:08
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:10
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:13
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:16
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:18
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:21
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:24
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:27
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:29
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:33
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:34
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:39
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:40
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:44
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:45
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:50
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 19:55
@justinmoon justinmoon restored the wt-d1a8796d branch March 21, 2026 19:59
@justinmoon justinmoon deleted the wt-d1a8796d branch March 21, 2026 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant