Skip to content

ls: restore WASI ".." metadata fallback in collect_directory_entries#11930

Merged
sylvestre merged 2 commits intouutils:mainfrom
sylvestre:ls-dot
Apr 22, 2026
Merged

ls: restore WASI ".." metadata fallback in collect_directory_entries#11930
sylvestre merged 2 commits intouutils:mainfrom
sylvestre:ls-dot

Conversation

@sylvestre
Copy link
Copy Markdown
Contributor

The ls refactor in #9851 dropped the WASI guard added in #11633, so ls -al at a preopened root once again fails with "Capabilities insufficient" when stat'ing "..". Extract the logic into a small dotdot_path helper and add a regression test covering ls -al.

The ls refactor in uutils#9851 dropped the WASI guard added in uutils#11633, so
`ls -al` at a preopened root once again fails with "Capabilities
insufficient" when stat'ing "..". Extract the logic into a small
`dotdot_path` helper and add a regression test covering `ls -al`.
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 21, 2026

GNU testsuite comparison:

Skip an intermittent issue tests/pr/bounded-memory (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/date/date-locale-hour (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/date/resolution (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/tty/tty-eof (passes in this run but fails in the 'main' branch)
Congrats! The gnu test tests/unexpand/bounded-memory is now passing!

@sylvestre sylvestre marked this pull request as ready for review April 22, 2026 06:49
@sylvestre
Copy link
Copy Markdown
Contributor Author

note: it breaks the playground wasm test suite

Comment thread tests/by-util/test_ls.rs

#[test]
#[cfg(target_os = "wasi")]
fn test_ls_al_no_capabilities_insufficient_on_wasi() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Are you aware that this test is currently not run in the CI?

@cakebaker
Copy link
Copy Markdown
Contributor

note: it breaks the playground wasm test suite

Hm, what does that mean? Should I wait with merging?

@sylvestre sylvestre merged commit fd781df into uutils:main Apr 22, 2026
169 checks passed
@sylvestre
Copy link
Copy Markdown
Contributor Author

this will unbreak the ci

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.

2 participants