Skip to content

Commit dce84cf

Browse files
branchseerclaude
andcommitted
Fix CI failures: remove unused deps, fix clippy, add missing test fixtures
- Remove unused `rustc-hash` from vite_task_bin dependencies - Remove unused `which` from vite_task_graph dev-dependencies - Fix clippy: use `Result::ok` instead of redundant `|e| e.ok()` closure in vtt.rs - Add SAFETY comment for `libc::dup2` unsafe block in vtt.rs (undocumented-unsafe-blocks) - Add missing `folder1/` and `folder2/` directories to builtin-different-cwd fixture (the cd builtin changes CWD before spawning vtt, which fails with ENOENT if the directory doesn't exist) - Fix direct lint snapshot: update quote style to match actual main.js content Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent e089b46 commit dce84cf

File tree

7 files changed

+4
-6
lines changed

7 files changed

+4
-6
lines changed

Cargo.lock

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/vite_task_bin/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ libc = { workspace = true }
2020
async-trait = { workspace = true }
2121
clap = { workspace = true, features = ["derive"] }
2222
jsonc-parser = { workspace = true }
23-
rustc-hash = { workspace = true }
2423
serde_json = { workspace = true }
2524
tokio = { workspace = true, features = ["full"] }
2625
vite_path = { workspace = true }

crates/vite_task_bin/src/vtt.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ fn cmd_barrier(args: &[String]) -> Result<(), Box<dyn std::error::Error>> {
9393
// Poll until <count> matching files exist.
9494
loop {
9595
let matches = std::fs::read_dir(dir)?
96-
.filter_map(|e| e.ok())
96+
.filter_map(Result::ok)
9797
.filter(|e| e.file_name().to_string_lossy().starts_with(&std::format!("{prefix}_")))
9898
.count();
9999
if matches >= count {
@@ -111,6 +111,8 @@ fn cmd_barrier(args: &[String]) -> Result<(), Box<dyn std::error::Error>> {
111111
use std::os::unix::io::IntoRawFd;
112112
let null1 = std::fs::OpenOptions::new().write(true).open("/dev/null").unwrap();
113113
let null2 = std::fs::OpenOptions::new().write(true).open("/dev/null").unwrap();
114+
// SAFETY: fds 1 and 2 are always valid (stdout/stderr), and null1/null2 are
115+
// valid open file descriptors. dup2 is safe to call with valid fd arguments.
114116
unsafe {
115117
libc::dup2(null1.into_raw_fd(), 1);
116118
libc::dup2(null2.into_raw_fd(), 2);

crates/vite_task_bin/tests/e2e_snapshots/fixtures/builtin-different-cwd/folder1/.gitkeep

Whitespace-only changes.

crates/vite_task_bin/tests/e2e_snapshots/fixtures/builtin-different-cwd/folder2/.gitkeep

Whitespace-only changes.

crates/vite_task_bin/tests/e2e_snapshots/fixtures/e2e-lint-cache/snapshots/direct lint.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ expression: e2e_outputs
44
---
55
> vt run lint # cache miss
66
$ vt tool print-file main.js
7-
console.log("hello");
7+
console.log('hello');
88
> echo modified > main.js # modify tracked file
99

1010
> vt run lint # cache miss, file changed

crates/vite_task_graph/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ pretty_assertions = { workspace = true }
2828
ts-rs = { workspace = true, features = ["no-serde-warnings"] }
2929
vite_path = { workspace = true, features = ["ts-rs"] }
3030
vite_str = { workspace = true, features = ["ts-rs"] }
31-
which = { workspace = true }
3231

3332
[lints]
3433
workspace = true

0 commit comments

Comments
 (0)