Skip to content

Port packages/tools bins to single Rust binary (vtt)#291

Open
branchseer wants to merge 20 commits intomainfrom
claude/port-bins-rust-Ryl0L
Open

Port packages/tools bins to single Rust binary (vtt)#291
branchseer wants to merge 20 commits intomainfrom
claude/port-bins-rust-Ryl0L

Conversation

@branchseer
Copy link
Member

@branchseer branchseer commented Mar 23, 2026

Summary

  • Replace all 8 Node.js test utilities in packages/tools with a single Rust binary vtt using subcommands
  • Remove pnpm install in packages/tools as a test prerequisite
  • Remove cross-env dependency — use native ENV=VALUE shell syntax

CI Time Comparison

Platform Main (Node.js) PR (Rust vtt) Improvement
Linux (x86_64-gnu) 130s 113s -13%
Linux (musl) 282s 255s -10%
macOS (x86_64) 383s 219s -43%
Windows 416s 329s -21%
macOS (aarch64) 113s 126s +12% (noise)

Test plan

  • All e2e and plan snapshot tests pass on all platforms
  • Clippy and formatting pass

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG

@chatgpt-codex-connector
Copy link

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Ports the repository’s test utilities from multiple Node.js-based binaries under packages/tools to a single Rust-built vtt binary (with subcommands), and updates plan/e2e snapshot fixtures accordingly to reduce CI setup time and remove the packages/tools pnpm install prerequisite.

Changes:

  • Introduces a new Rust binary vtt (in crates/vite_task_bin) and updates test fixtures to call vtt <subcommand> instead of individual Node tool binaries.
  • Updates e2e/plan snapshot redaction + PATH expectations (including duration redaction and PATH <tools> mapping).
  • Adjusts Rust build profiles for tests ([profile.test] debug = false) and updates many snapshots/fixtures to reflect the new toolchain and output.

Reviewed changes

Copilot reviewed 216 out of 216 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
Cargo.toml Disables debug symbols for test profile to reduce build/CI overhead.
crates/vite_task_bin/Cargo.toml Adds vtt as a second binary target in vite_task_bin.
crates/vite_task_bin/src/lib.rs Adds synthesize_vtt_task and routes env-test to vtt print-env.
crates/vite_task_bin/src/main.rs Switches synthetic FOO exec hook to run vtt print-env FOO.
crates/vite_task_bin/src/vtt.rs New Rust implementation of prior Node test utilities as a single vtt CLI with subcommands.
crates/vite_task_bin/tests/e2e_snapshots/main.rs Updates PATH setup to rely on target-dir binaries (vt/vtt) rather than packages/tools/node_modules/.bin.
crates/vite_task_bin/tests/e2e_snapshots/redact.rs Improves Windows path normalization and makes duration/saved-time output redaction more stable.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/vite-task-smoke/package.json Switches script utilities to vtt ....
crates/vite_task_bin/tests/e2e_snapshots/fixtures/vite-task-smoke/snapshots.toml Uses vtt commands in test steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/vite-task-smoke/snapshots/cache hit after file modification.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/packages/a/package.json Switches print usage to vtt print.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/packages/b/package.json Switches print usage to vtt print.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/single task verbose shows full summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/single task cache miss shows no summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/single task cache hit shows compact summary.snap Snapshot updates; removes variable “saved” duration suffix.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/multi task with cache hits shows compact summary.snap Snapshot updates; removes variable “saved” duration suffix.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/multi task verbose with cache hits shows full summary.snap Snapshot updates; removes variable “saved” duration suffix and adjusts task lines.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/multi task verbose shows full summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/multi task all cache miss shows compact summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/last details after run shows saved summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/summary-output/snapshots/last details after multi task run shows saved summary.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/shared-caching-input/package.json Switches to vtt utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/shared-caching-input/snapshots.toml Uses vtt in steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/shared-caching-input/snapshots/shared caching input.snap Snapshot updates for vtt utilities and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/replay-logs-chronological-order/snapshots/replay logs chronological order.snap Snapshot updates; removes variable “saved” duration suffix.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/vite-task.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/packages/other/package.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/stdin is always null.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/single task, cache off, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/single task, cache miss, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/single task, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/multiple tasks, cache off, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/multiple tasks, cache miss, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/labeled-stdio/snapshots/multiple tasks, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/vite-task.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/packages/other/package.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/single task, cache off, inherits stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/single task, cache miss, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/single task, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/multiple tasks, cache off, inherit stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/multiple tasks, cache miss, piped stdio.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/multiple tasks, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/cache on gets null stdin.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/interleaved-stdio/snapshots/cache off inherits stdin.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/vite-task.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/packages/other/package.json Uses vtt subcommands for stdio utilities.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/stdin is always null.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/single task, cache off, grouped output.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/single task, cache miss, grouped output.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/single task, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/multiple tasks, cache off, grouped output.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/multiple tasks, cache miss, grouped output.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/grouped-stdio/snapshots/multiple tasks, cache hit, replayed.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-subcommand/vite-task.json Uses vtt print-file for cached-task fixture.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-subcommand/snapshots/cache clean.snap Snapshot updates for vtt and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-disabled/vite-task.json Uses vtt print-file in cache enable/disable fixtures.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-disabled/snapshots/task with cache enabled.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-disabled/snapshots/task with cache disabled.snap Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-command-change/vite-task.json Updates commands to use vtt print in multi-subtask scenario.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-command-change/snapshots.toml Uses vtt json-edit in steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-command-change/snapshots/cache miss command change.snap Snapshot updates for vtt and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/vite-task.json Updates commands to use vtt tools.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots.toml Removes cross-env usage; switches edit/replace commands to vtt.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/env value changed.snap Uses MY_ENV=... shell syntax + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/env added.snap Uses MY_ENV=... shell syntax + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/env removed.snap Uses MY_ENV=... shell syntax + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/untracked env added.snap Uses vtt json-edit + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/untracked env removed.snap Uses vtt json-edit + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/input config changed.snap Uses vtt json-edit + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/inferred input changes.snap Uses vtt replace-file-content + vtt print-file.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/glob input changes.snap Uses vtt replace-file-content + vtt print.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/cache-miss-reasons/snapshots/cwd changed.snap Uses vtt json-edit to set cwd.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/associate-existing-cache/package.json Uses vtt print scripts.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/associate-existing-cache/snapshots.toml Uses vtt json-edit in steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/associate-existing-cache/snapshots/associate existing cache.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-read-write-not-cached/snapshots.toml Updates docs/steps to reference vtt replace-file-content.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-read-write-not-cached/packages/normal-pkg/package.json Uses vtt print script.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-read-write-not-cached/packages/rw-pkg/package.json Uses vtt replace-file-content script.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-read-write-not-cached/packages/touch-pkg/package.json Uses vtt touch-file script.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-read-write-not-cached/snapshots/* Snapshot updates for vtt tools and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-cache-test/vite-task.json Uses vtt tools and normalizes JSON formatting for input arrays/objects.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-cache-test/snapshots/* Snapshot updates for vtt tools and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-negative-glob-subpackage/packages/sub-pkg/vite-task.json Uses vtt tools and normalizes JSON formatting for input arrays/objects.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-negative-glob-subpackage/snapshots.toml Uses vtt replace-file-content in steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-negative-glob-subpackage/snapshots/* Snapshot updates for vtt tools and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-glob-meta-in-path/packages/[lib]/vite-task.json Uses vtt print-file in task command.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-glob-meta-in-path/snapshots.toml Uses vtt replace-file-content in steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/input-glob-meta-in-path/snapshots/cache hit then miss on file change.snap Snapshot updates for vtt tools and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/glob-base-test/vite-task.json Uses vtt print-file task commands.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/glob-base-test/packages/sub-pkg/vite-task.json Uses vtt print-file task commands.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/glob-base-test/snapshots.toml Uses vtt replace-file-content steps.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/glob-base-test/snapshots/* Snapshot updates for vtt tools and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/filter-unmatched/packages/app/package.json Uses vtt print in scripts.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/filter-unmatched/packages/lib/package.json Uses vtt print in scripts.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/filter-unmatched/snapshots/* Snapshot updates for vtt command output.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/individual-cache-for-env/vite-task.json Uses vtt print-env task command.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/individual-cache-for-env/snapshots/individual cache for env.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/individual-cache-for-adt-args/package.json Uses vtt print script.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/individual-cache-for-adt-args/snapshots/individual cache for extra args.snap Snapshot updates and saved-time normalization.
crates/vite_task_bin/tests/e2e_snapshots/fixtures/colon-in-name/snapshots/read file with colon in name.snap Snapshot updates and saved-time normalization.
crates/vite_task_plan/tests/plan_snapshots/redact.rs Updates <tools> redaction from packages/tools to the Cargo target binary directory.
crates/vite_task_plan/tests/plan_snapshots/fixtures/**/package.json Updates fixture scripts to invoke vtt ... instead of Node tool bins.
crates/vite_task_plan/tests/plan_snapshots/fixtures/**/vite-task.json Updates fixture task commands to invoke vtt ... instead of Node tool bins and normalizes JSON formatting.
crates/vite_task_plan/tests/plan_snapshots/fixtures/**/snapshots/*.snap Snapshot updates reflecting vtt program path/args, PATH changes, and some error expectations.
Comments suppressed due to low confidence (1)

crates/vite_task_bin/tests/e2e_snapshots/main.rs:285

  • The e2e test runner PATH now only prepends the vt/vtt target directory (then chains the existing PATH). Fixtures that invoke vt lint / vt test rely on the CommandHandler synthesizing oxlint/vitest from PATH + node_modules/.bin; without installing those tools, many scenarios degrade into cannot find binary path errors, which reduces coverage of lint/test planning + caching behavior. Consider providing lightweight stubs for oxlint/vitest (e.g., via vtt subcommands or small wrapper binaries in the same directory) and ensuring that directory is on PATH for the tests, so these scenarios continue to exercise the intended code paths instead of the error path.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +73 to +92
/// Create a synthetic plan request for running a `vtt` subcommand.
///
/// # Errors
///
/// Returns an error if the `vtt` executable cannot be found.
fn synthesize_vtt_task(
subcommand: &str,
args: &[Str],
cache_config: UserCacheConfig,
envs: &Arc<FxHashMap<Arc<OsStr>, Arc<OsStr>>>,
cwd: &Arc<AbsolutePath>,
) -> anyhow::Result<SyntheticPlanRequest> {
let mut full_args = vec![Str::from(subcommand)];
full_args.extend_from_slice(args);
Ok(SyntheticPlanRequest {
program: find_executable(get_path_env(envs), cwd, "vtt")?,
args: full_args.into(),
cache_config,
envs: Arc::clone(envs),
})
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

Now that synthesize_vtt_task exists, vt env-test is routed through vtt, but vt lint/vt test are still synthesized via oxlint/vitest lookup in PATH + node_modules/.bin. In CI/test environments where Node dependencies aren’t installed (one of the PR goals), this causes planning/execution failures and snapshot updates that assert errors instead of validating behavior. Consider adding a fallback path that synthesizes vtt-backed stubs for lint/test when oxlint/vitest aren’t available, so tests remain self-contained while keeping the production path unchanged when real tools are installed.

Copilot uses AI. Check for mistakes.
Comment on lines +14 to +43
fn main() {
let args: Vec<String> = std::env::args().collect();
if args.len() < 2 {
eprintln!("Usage: vtt <subcommand> [args...]");
eprintln!(
"Subcommands: check-tty, json-edit, print, print-env, print-file, read-stdin, replace-file-content, touch-file"
);
std::process::exit(1);
}

let result: Result<(), Box<dyn std::error::Error>> = match args[1].as_str() {
"check-tty" => {
cmd_check_tty();
Ok(())
}
"json-edit" => cmd_json_edit(&args[2..]),
"print" => {
cmd_print(&args[2..]);
Ok(())
}
"print-env" => cmd_print_env(&args[2..]),
"print-file" => cmd_print_file(&args[2..]),
"read-stdin" => cmd_read_stdin(),
"replace-file-content" => cmd_replace_file_content(&args[2..]),
"touch-file" => cmd_touch_file(&args[2..]),
other => {
eprintln!("Unknown subcommand: {other}");
std::process::exit(1);
}
};
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

vtt replaces the Node-based test utilities, but it currently doesn’t provide stubs for the synthesized vt lint/vt test commands (which look for oxlint/vitest). This is why several snapshot fixtures now record cannot find binary path errors. Adding minimal vtt subcommands that emulate the expected oxlint/vitest behavior used in snapshots would let tests keep exercising lint/test execution and caching logic without reintroducing a Node install step.

Copilot uses AI. Check for mistakes.
claude and others added 14 commits March 24, 2026 12:34
Replace all 8 Node.js test utilities (check-tty, json-edit, print,
print-env, print-file, read-stdin, replace-file-content, touch-file)
with a single Rust binary `vtt` using subcommands. This eliminates
the need for `pnpm install` in packages/tools before running e2e/plan
tests, and removes the cross-env dependency by using native ENV=VALUE
shell syntax.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
…neration

- Run cargo fmt and oxfmt to fix formatting issues
- Add 'ns' to duration redaction regex (Rust tools are fast enough to show 0ns)
- Regenerate all plan snapshots and modified e2e snapshots
- Restore unmodified e2e snapshots from parent commit

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
The Rust vtt binary is fast enough that cache hits may save 0ns, causing
the runner to omit the time-saved suffix. Strip it in redaction so
snapshots are stable regardless of tool speed.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
On Windows, canonicalize() produces verbatim paths (\\?\C:\...) while
child processes may report paths without this prefix. Try both variants
when redacting workspace root paths in e2e test output.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
Path::Debug on Windows escapes backslashes to double-backslashes (\\).
Add escaped workspace_root variant to redaction list to match these
paths in error messages formatted with {:?}.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
When a Debug-format path with escaped backslashes (\\) is partially
replaced, the remaining \\ gets normalized to //, producing double
forward slashes. Collapse them to single slashes.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
- Also escape the full workspace root (with \\?\ prefix) for matching
  Debug-format paths that include the verbatim prefix
- Strip "in total" from verbose performance summary (omitted when
  saved time is 0ns on fast Rust tools)

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
Add redact_error_string() helper that handles escaped backslashes from
Debug-format paths in error messages. Also fix attribute placement.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
Full --release builds are 3-5x slower due to compilation overhead.
Instead, follow oxc's approach: optimize only the snapshot testing
dependencies (insta, similar) at opt-level=3 in dev profile. This
speeds up snapshot diffing without penalizing compile times.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
The opt-level=3 for insta/similar adds recompilation time that exceeds
the snapshot diffing speedup. Plain debug builds with Rust vtt are
already the fastest configuration.

https://claude.ai/code/session_01MM41gBUbWHBiX8Skve91rG
…6902)

Replace custom path/value parsing with standard JSON Patch operations,
reducing ~150 lines of hand-rolled code to a 4-line implementation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@branchseer branchseer force-pushed the claude/port-bins-rust-Ryl0L branch from eed778c to 7cd9746 Compare March 24, 2026 09:41
branchseer and others added 4 commits March 24, 2026 17:55
Use `join(runtime_manifest, diff(compile_time_bin, compile_time_manifest))`
consistently for both binaries. Add build.rs to vite_task_plan to emit
compile-time binary paths. Don't assume vt and vtt share the same directory.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
vtt needs to be built alongside vt for tests, so keep the [[bin]] entry
in vite_task_bin with a thin wrapper that calls vite_task_tools::main().
This ensures CARGO_BIN_EXE_vtt is available in e2e tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@branchseer branchseer force-pushed the claude/port-bins-rust-Ryl0L branch 5 times, most recently from d027c9b to e49d295 Compare March 24, 2026 12:15
replace-file-content now errors with exit 1 when searchValue is not
found. All test fixtures converted from json-patch to replace-file-content.
Removes json-patch and serde_json dependencies from vite_task_tools.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@branchseer branchseer force-pushed the claude/port-bins-rust-Ryl0L branch from e49d295 to fe23bd3 Compare March 24, 2026 12:45
…vTest

- Args now only has Task (forwarded to session.main) and Tool (finds vtt
  in PATH and synthesizes a plan request)
- Remove session.execute_synthetic and all related test fixtures (exec-api,
  e2e-env-test)
- Convert builtin-different-cwd to use print-cwd, lint-dot-git and
  e2e-lint-cache to use print-file, builtin-non-zero-exit to use
  replace-file-content with missing searchValue
- Update plan fixtures from vt lint to vt tool print lint, and
  vt env-test to TEST_VAR=val vt tool print-env

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

4 participants