Repository navigation
rm: report traversal failed on getdents EIO - #15209
Franklin-Qi wants to merge 1 commit into
Conversation
d0e68dc to
63bd6f2
Compare
Merging this PR will improve performance by 4.45%
|
| Mode | Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|---|
| ⚡ |
Simulation | rm_recursive_tree |
14.4 ms | 13.8 ms | +4.45% |
Tip
Curious why performance improved? Comment @codspeedbot explain why performance improved on this PR, or directly use the CodSpeed MCP with your agent.
Comparing Franklin-Qi:feature-issue#15206-rm-traversal-failed (166a6a6) with main (175f6e1)2
Footnotes
-
464 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩
-
No successful run was found on
main(b8657e8) during the generation of this report, so 175f6e1 was used instead as the comparison base. There might be some changes unrelated to this pull request in this report. ↩
63bd6f2 to
13e0456
Compare
13e0456 to
444e7a5
Compare
When directory listing fails mid-walk (e.g. injected getdents EIO), emit GNU's "traversal failed" even under -f instead of later "Directory not empty". Closes: uutils#15206
444e7a5 to
166a6a6
Compare
| /// even under `-f`. Without that, rm later fails with "Directory not empty". | ||
| #[test] | ||
| #[cfg(target_os = "linux")] | ||
| #[cfg(not(wasi_runner))] |
There was a problem hiding this comment.
WASMTIME_LOG can't unblock these tests — it's trace-only, with no fault= equivalent to inject the getdents64 EIO — so #[cfg(not(wasi_runner))] is correct. It's still a useful WASI-side strace substitute for debugging; #15453 wires it into wasi.yml.
| .current_dir(scene.fixtures.as_string()) | ||
| .output() | ||
| else { | ||
| return; // missing strace |
There was a problem hiding this comment.
this only skips if strace is missing, if ptrace is blocked (containers) strace fails and the test fails too. could you please probe like test_no_preserve_root_literal_root does?
| #[test] | ||
| #[cfg(target_os = "linux")] | ||
| #[cfg(not(wasi_runner))] | ||
| fn test_recursive_getdents_eio_subdirectory_reports_traversal_failed() { |
There was a problem hiding this comment.
this is almost the same code as the test above, could you please dedup with a helper taking the when= and the expected path?
When directory listing fails mid-walk (e.g. injected getdents EIO), emit GNU's "traversal failed" even under -f instead of later "Directory not empty".
Closes: #15206