You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "heeoneie (via GitHub)" <gi...@apache.org> on 2026/08/26 09:14:33 UTC

[PR] fix(runtime): pass option-like Grep patterns after a -- separator [maka]

heeoneie opened a new pull request, #3903:
URL: https://github.com/apache/maka/pull/3903

   ## Summary
   
   The sandboxed filesystem worker appended the Grep pattern as a bare positional, so ripgrep parsed a pattern starting with `-` as flags. `-webkit-box` made rg exit 1, which `operations.ts` maps to `{ kind: 'grep', matches: [] }` — the model was told the string is absent from a file that contains it, with no error and no diagnostic.
   
   The host-local sibling already handles this at `workspace-executor.ts:455`; this change mirrors it in the worker.
   
   Fixes #3733
   
   ## Verification
   
   Confirmed the underlying behaviour against ripgrep directly:
   
   ```
   rg -n --no-heading --max-count=50 '-webkit-box' file.ts      -> exit 1, no output
   rg -n --no-heading --max-count=50 -- '-webkit-box' file.ts   -> exit 0, 1:const style = "-webkit-box";
   ```
   
   Ran locally against `packages/runtime`:
   
   - `npm --workspace @maka/core run build`, `@maka/storage`, `@maka/runtime` — all clean
   - `node --test dist/__tests__/filesystem-worker.test.js` — the new test passes; pass count goes 19 -> 20 with no new failures
   - `biome lint` and `biome format` on both changed files — clean
   
   Not run: the full workspace suite and the desktop app. This sandbox could not complete a root `npm install` (the registry mirror blocks `@xterm/xterm`, and the Electron postinstall cannot reach its download host), so only the `core` / `storage` / `runtime` workspaces were built and exercised.
   
   One pre-existing failure in that file — `reports no diff — not a new-file diff — when an existing file cannot be read` — fails on unmodified `main` in this environment too, because the test runs as root and `chmod 000` does not deny root. Unrelated to this change.
   
   ## AI use
   
   Select exactly one:
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: Claude (Anthropic) — drafted the one-line fix and the regression test, and ran the local verification above. Reviewed and submitted by me. `Generated-by: Claude` trailers are on both commits.
   
   ## Checklist
   
   - [x] Tests cover the change and fail without it
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [x] Yes — described under Summary above
   - [ ] No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] fix(runtime): pass option-like Grep patterns after a -- separator [maka]

Posted by "M4n5ter (via GitHub)" <gi...@apache.org>.
M4n5ter merged PR #3903:
URL: https://github.com/apache/maka/pull/3903


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] fix(runtime): pass option-like Grep patterns after a -- separator [maka]

Posted by "M4n5ter (via GitHub)" <gi...@apache.org>.
M4n5ter commented on PR #3903:
URL: https://github.com/apache/maka/pull/3903#issuecomment-5433143355

   Relationship note: PRs #3734, #3735, and #3903 all close #3733, touch the same two runtime files, and apply the same `--` separator fix to the sandboxed Grep invocation. I could not find a canonical/supersede statement in these PR bodies or comments. At the current snapshot, this is the latest-created candidate, but the owner should decide the canonical PR. Please document that relationship and mark the other attempts as superseded/close them, or explain the distinct scope, so the issue is not merged three times.
   
   This comment records the relationship only; it is not a merge decision.
   
   ---
   _Automated review note posted by @未开智选手. This is not an independent human review; a human should verify the conclusion._
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org