Repository navigation
[codex] Pin WebUI v2 frontend Node tooling - #5384
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (4)
📝 WalkthroughSummary by CodeRabbit
WalkthroughPins Node.js to version 22 in ChangesNode.js 22 Pin and Build Improvements
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (3 passed)
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.
Code Review
This pull request updates the Node.js version requirements to Node 22 across configuration files and frontend package manifests. It also updates the Rust build script to trigger rebuilds when static files change. The feedback recommends using relative paths instead of absolute paths in the cargo:rerun-if-changed instruction to ensure build caching and reproducibility are not broken.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| println!("cargo:rerun-if-changed={}", path.display()); | ||
| let rel = path.strip_prefix(root).expect("strip prefix"); // safety: build script — strip_prefix only fails on a logic bug |
There was a problem hiding this comment.
Emitting absolute paths via cargo:rerun-if-changed can break build caching and reproducibility (e.g., when using distributed compilation tools like sccache or sandboxed environments like Nix/Bazel) because the paths contain local workspace directory structures.
Instead, we should emit paths relative to the crate root (CARGO_MANIFEST_DIR). Since root represents the static directory, we can strip the prefix and construct a relative path starting with static/.
| println!("cargo:rerun-if-changed={}", path.display()); | |
| let rel = path.strip_prefix(root).expect("strip prefix"); // safety: build script — strip_prefix only fails on a logic bug | |
| let rel = path.strip_prefix(root).expect("strip prefix"); // safety: build script — strip_prefix only fails on a logic bug | |
| println!("cargo:rerun-if-changed={}", Path::new("static").join(rel).display()); |
References
- When relativizing paths, use
std::path::Path::strip_prefixonPathobjects rather than string manipulation, unless the string prefix is guaranteed to be exact.
|
🚅 Deployed to the ironclaw-pr-5384 environment in ironclaw-ci-preview
|
Summary
main..node-versionand.nvmrcfor Node 22.Context
#5370 was accidentally merged into the stacked branch
codex/reborn-openai-responsesafter #5347 had already landed onmain. This PR cherry-picks only that five-file tooling change onto a fresh branch fromorigin/main.Validation
node --version && npm --version && npm install --package-lock-only --prefix crates/ironclaw_webui_v2_static/frontendcargo fmt --all -- --checkgit diff --check origin/main...HEAD