A typed answer to an agent's question can't contain a space #281

Closed
opened 2026-10-28 16:23:58 -04:00 by cmoriarty · 1 comment
Owner

What happens

On an agent's question, "Type your own answer" takes letters but no spaces (found answering run 134's judge). GateCard.tsx stores the answer trimmed on every keystroke, setAnswer(index, text.trim() ? [text.trim()] : null), and the input shows the stored value. A space typed at the end is trimmed away at once; one typed mid-word survives.

Fix

Keep the text as typed in the field; trim it only when the answer is sent.

Done when

A typed answer with spaces can be entered and is sent trimmed, with a UI test that types one.

From #279.

**What happens** On an agent's question, "Type your own answer" takes letters but no spaces (found answering run 134's judge). `GateCard.tsx` stores the answer trimmed on every keystroke, `setAnswer(index, text.trim() ? [text.trim()] : null)`, and the input shows the stored value. A space typed at the end is trimmed away at once; one typed mid-word survives. **Fix** Keep the text as typed in the field; trim it only when the answer is sent. **Done when** A typed answer with spaces can be entered and is sent trimmed, with a UI test that types one. _From #279._
Author
Owner

Shipped in PR #284 (merge 8c527d6), live on production.

Verified by ui/e2e/gates.spec.ts ("an agent's question is answered in the operator's own words, spaces and all"), which types use pyjwt key by key and checks that use pyjwt is sent, green in CI and in the suite. The deployed console keeps the text as typed and trims it on send.

Shipped in PR #284 (merge 8c527d6), live on production. Verified by `ui/e2e/gates.spec.ts` ("an agent's question is answered in the operator's own words, spaces and all"), which types `use pyjwt ` key by key and checks that `use pyjwt` is sent, green in CI and in the suite. The deployed console keeps the text as typed and trims it on send.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cmoriarty/braid#281
No description provided.