fix(providers): CursorAgent deliver prompt via @path to saved file#185
fix(providers): CursorAgent deliver prompt via @path to saved file#185Spencer1O1 wants to merge 2 commits into
Conversation
99 saves the full prompt to tmp/99-*-prompt before make_request. Pass a single-line --print message referencing that file with @ instead of putting the multiline XML query on argv. Closes ThePrimeagen#180
|
Bugbot is not enabled for this team, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
Try normalized and cwd-relative candidates; do not return an unreadable fallback path. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Bugbot is not enabled for this team, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
Re: Sentry — valid edge case, fixed in 44e14c2. The cwd fallback was returned without a filereadable check. Now both candidates are tried in order and only a readable path is returned. Normal flow is unaffected: finalize() creates the prompt file via _ready_request_files before save_prompt/make_request. If no candidate is readable (I/O failure), we still fall back to the primary normalized path so the agent error is visible rather than silently using a wrong cwd path. |
Summary
99 saves the full prompt to
tmp/99-*-promptbeforemake_request. StockCursorAgentProviderpasses the entire multiline XMLqueryas the--printargv argument, which breaks on Windows when Neovim cwd differs from the project root.Deliver the prompt via a single-line
--printmessage that references the saved file with@absolute/pathinstead.Same pattern as #154 proposes for OpenCode (
--file).Closes #180
Verification
Windows 11 — search in
C:\Dev\test. Before fix: multiline<Context>on--print→ agent "Your message looks incomplete". After:Linux (WSL) — search, same branch:
Test plan
@and99-*-prompt, no<Context>