1 Commits

Author SHA1 Message Date
Bob
9b95f64e45
fix(sandbox): make glob patterns root-relative with recursive ** (#6046)
path_matches backs the glob tool and grep's glob= filter for every sandbox provider. It relied on PurePosixPath.match, which matches from the right and treats ** as a single-segment * on Python 3.12+, so only a leading **/ was recursive: src/**/*.py missed src/top.py and anything two or more levels deep, and docs/*.md also matched vendor/docs/b.md.

Match patterns that contain a / segment by segment from the search root, with ** spanning zero or more directories. Patterns without / keep matching the basename at any depth.
2026-09-29 21:50:59 +08:00