Skip to content

Fix glob pattern matching#35

Merged
jakekaplan merged 1 commit intomainfrom
fix-globs
Jan 19, 2026
Merged

Fix glob pattern matching#35
jakekaplan merged 1 commit intomainfrom
fix-globs

Conversation

@jakekaplan
Copy link
Owner

@jakekaplan jakekaplan commented Jan 19, 2026

We were deviating from typical path-glob behavior: * was matching across directory separators
because we didn’t set literal_separator(true) in globset. That made patterns like src/*.rs match
src/nested/file.rs, which is unexpected for most users.

Old behavior:

  • src/*.rs matched src/lib.rs and src/nested/lib.rs
  • *.rs matched files in subdirectories too

New behavior:

  • * stays within a single path segment
  • ** is required to match across directories (e.g. src/**/*.rs)

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Benchmark

Details
Benchmark suite Current: 573c795 Previous: d600992 Ratio
cpython 0.051887353059999995 seconds (± 0.0031) 0.053392845060000006 seconds (± 0.0039) 0.97
airflow 0.14357618655999999 seconds (± 0.0006) 0.14550399256 seconds (± 0.0018) 0.99
prefect 0.06001727946 seconds (± 0.0002) 0.06112902856 seconds (± 0.0007) 0.98
ruff 0.12550913466 seconds (± 0.0011) 0.12826274716 seconds (± 0.001) 0.98

This comment was automatically generated by workflow using github-action-benchmark.

@codecov
Copy link

codecov bot commented Jan 19, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.51%. Comparing base (d600992) to head (573c795).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #35      +/-   ##
==========================================
+ Coverage   98.50%   98.51%   +0.01%     
==========================================
  Files          19       19              
  Lines        2747     2769      +22     
==========================================
+ Hits         2706     2728      +22     
  Misses         41       41              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jakekaplan jakekaplan marked this pull request as ready for review January 19, 2026 18:49
@jakekaplan jakekaplan merged commit baf5c6e into main Jan 19, 2026
9 checks passed
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.

1 participant