You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Workspace.search returns nothing, without an error, when rg is missing on the client #15112
When rg isn't on the client's PATH, Workspace.search falls back to grep (engine/client/filesync.go, searchHostPath → searchWithGrep, v1.0.0-beta.25). Globs become grep --include, which has no brace expansion or ! negation, so *.{test,spec}.ts matches nothing, grep exits 1, and the search returns [] without an error.
dagger/vitest v0.3.0 finds test files this way. On stock ubuntu:24.04 with one failing test, dagger check lists 3 checks and exits 0; after apt-get install ripgrep it lists 5 and exits 1.
I'd like to work on this. searchWithGrep in engine/client/filesync.go passes each glob to grep --include, which doesn't understand {a,b} or !, and exit status 1 is then read as "no matches", so the caller gets an empty result.
The fix I have in mind follows your request: return a clear error saying ripgrep is required when a glob uses syntax the grep fallback can't honor, instead of an empty result, plus a unit test with *.{test,spec}.ts. Happy to adjust if you'd rather handle it differently.
Activity
pcbeingused333 commentedon Nov 9, 2026
I'd like to work on this.
searchWithGrepinengine/client/filesync.gopasses each glob togrep --include, which doesn't understand{a,b}or!, and exit status 1 is then read as "no matches", so the caller gets an empty result.The fix I have in mind follows your request: return a clear error saying ripgrep is required when a glob uses syntax the grep fallback can't honor, instead of an empty result, plus a unit test with
*.{test,spec}.ts. Happy to adjust if you'd rather handle it differently.(Written with AI assistance.)