| … | … | @@ -802,29 +804,33 @@ export function useComposerSend(input: ComposerSendInput) { | |
| 826 | 812 | text: messageTextForSend || ATTACHMENT_ONLY_BOOTSTRAP_PROMPT, | |
| 827 | 813 | }); | |
| 814 | + | const buildOutgoingMessageContext = (attachmentIds: ReadonlyArray<string>) => | |
| 815 | + | composerRecallContext( | |
🟠 High chat/useComposerSend.ts:815
Plain approval feedback with leading or trailing whitespace is rejected instead of calling sendApprovalFeedback: composerRecallContext makes outgoingMessageContext defined even when there are no added context records, and the feedback guard treats that metadata as added context. Check the actual context records in the guard rather than whether outgoingMessageContext is defined.
🤖 Copy this AI Prompt to have your agent fix this:
| 1 | In file @apps/web/src/components/chat/useComposerSend.ts around line 815: |
| 2 | |
| 3 | Plain approval feedback with leading or trailing whitespace is rejected instead of calling `sendApprovalFeedback`: `composerRecallContext` makes `outgoingMessageContext` defined even when there are no added context records, and the feedback guard treats that metadata as added context. Check the actual context records in the guard rather than whether `outgoingMessageContext` is defined. |
Confirmed and fixed in e2f0777b20. Approval feedback checks actual context records, not the presence of the context envelope. The regression sends whitespace-preserving plain text through the feedback eligibility decision and keeps real attachments/context rejected; it failed before the fix and passes now. check:changed passes, including 219 related tests.
Sorry, I'm unable to act on this request because you do not have permissions within this repository.
| … | … | @@ -1037,7 +1038,7 @@ export function NewTaskFlowProvider( | |
| 1038 | 1039 | text, | |
| 1039 | 1040 | attachments: draft.attachments, | |
| 1040 | - | context: draft.context, | |
| 1041 | + | context: composerRecallContext(text, draft.text, draft.context), | |
🟠 High threads/new-task-flow-provider.tsx:1041
Reopening and saving a queued task without changing its prompt drops the whitespace provenance, so later recall returns only the trimmed text. beginEditingPendingTask seeds the draft with message.text, while this call recomputes context from that trimmed text and discards the existing provenance; preserve draft.context when the draft text still matches the queued message.
✅ Resolved in e2f0777b20dbba7e5f8767771ca09bb26f362e3a
Confirmed and fixed in e2f0777b20. A queued editor now supplies the previous wire text so a no-op save preserves captured provenance; a real text edit still recomputes it. The new round-trip regression failed before this fix and passes now. check:changed passes, including 219 tests in 13 related files.
Sorry, I'm unable to act on this request because you do not have permissions within this repository.