Repository navigation
Keep files past PATH_MAX as path-table rows - #1656
Open
thekevinbot wants to merge 8 commits into
Open
thekevinbot wants to merge 8 commits into
thekevinbot wants to merge 8 commits into
Conversation
# Conflicts: # packages/rust/src/vtab.rs
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1582
A path table walking
'./**'silently dropped every file whose absolute path is longer thanPATH_MAX: the directory listing opened each directory by its full path and treatedENAMETOOLONGas an empty directory.The fix (
packages/rust/src/long_path.rs): on Unix, a path the kernel refuses as too long is opened again a stretch of components at a time, each stretchopenat-ed relative to the directory the previous one reached. The listing, the stat columns, symlink/unknown-type classification in the scanner, andcontentreads all go through it, so deep files keepsize,mtimeandcontent. Windows needs nothing: std already passes long paths in\\?\form, and the red test passed on Windows.Red run (test-only commit f90ef39,
Integration testsfails withleft: Integer(20) right: Integer(30)): https://github.com/thekevinscott/dirsql/actions/runs/41949428945/job/126989572880By hand: the issue's repro now prints
[{"n":30,"longest":6039}]; the deepest row reportssize1, a non-NULLmtime, andcontent"x".Merging main (#1585's
open_regular) resolved a conflict invtab.rs:open_regularnow opens throughlong_path::open_file, which opensO_NONBLOCKso the FIFO guard still holds. The non-unixopen_filebody is exempt from mutation intesting-conventions.toml, as it is compiled out on the Linux runner.Not covered here: declared
[[table]]freshness stats (RealFsinlib.rs) and a.gitignoresitting past the limit still use plain std paths.E2E Verification
packages/python/e2e-attestations/<branch>.jsonreceipt written ifpackages/pythonchanged (just e2e-attest-python)packages/ts/e2e-attestations/<branch>.jsonreceipt written ifpackages/tschanged (just e2e-attest-ts)cd packages/python && testing-conventions e2e attest 'uv run python -m pytest tests/e2e/glob_speed_recursive_test.py tests/e2e/glob_speed_symlink_test.py tests/e2e/stat_speed_test.py tests/e2e/query_contract_test.py tests/e2e/root_at_construction_test.py -x -q'cd packages/ts && testing-conventions e2e attest 'pnpm test:e2e'cargo test -p dirsql --features cli --test path_table_cli_e2e --test path_table_gitignore_cli_e2e --test path_max_depth_e2e --test path_table_symlinks --test path_table_globs --test path_table_query --test scanner --test scan_failuresChangelog / Migrations
<root>/<pkg>/changelog.d/for each changed package (or:skip-changelogtrailer on a commit with reason)<root>/<pkg>/migrations.d/for each changed package (every subsection but Summary_None._when nothing breaks)