@ 261027.5

261023.6 · fada8f9386df39e7fc9d0e407de764f005900ce0

ignore: benchmark Python workspace discovery and matching (#3554)

We add benchmarks for the ignore operations used by Ruff, uv, and ty: serial and parallel walks, early-exit workspace discovery, and incremental path matching. The 39 cases cover different project layouts, nested ignore rules, multiple roots, and cached directories.

We create fixtures before timing and check their expected file counts during walks. The README links the consumer call sites and describes how to compare profiles. These measure library work with a warm filesystem cache, not end-to-end application performance.

We also test these benchmarks in CI.

PR #3554

reading declarations

Changes to .github/workflows/ci.yml. All files

.github/workflows/ci.yml

@@ -252,6 +252,19 @@ jobs:           RUSTDOCFLAGS: -D warnings         run: cargo doc --no-deps --document-private-items --workspace +  benches:+    name: Test benchmarks+    runs-on: ubuntu-latest+    steps:+      - name: Checkout repository+        uses: actions/checkout@v4+      - name: Install Rust+        uses: dtolnay/rust-toolchain@master+        with:+          toolchain: nightly+      - name: Test ignore benchmarks+        run: cargo +nightly test -p ignore --benches+   fuzz_testing:     name: Compile Fuzz Test Targets     runs-on: ubuntu-latest