Skip to content

chat: a bare number-and-period reply draws instead of vanishing (#1072) - #1746

Merged
ZeroPoint95 merged 4 commits into
Agent-Field:devfrom
7vignesh:fix/1072-bare-number-reply
Oct 8, 2026
Merged

ZeroPoint95 merged 4 commits into
Agent-Field:devfrom
7vignesh:fix/1072-bare-number-reply

Conversation

@7vignesh

@7vignesh 7vignesh commented Oct 3, 2026

Copy link
Copy Markdown
Contributor

What changed

A model reply whose whole text is a number and a full stop (32., 1024.) parsed as a Markdown ordered list with one empty item. renderer.list in internal/tui2/prose pushed the marker column, rendered the empty item, and popped it as undrawn, taking the marker with it. The reply rendered to zero rows and the deck skipped it: the fold showed only the thought row though the transcript held the text (#1072).

The list renderer now draws the marker as the literal text the reader sent when the item body produced nothing. 32. stands under the chip; 1. one and multi-item lists still draw as lists.

Diff is 9 lines in render.go plus a guard test and a change entry.

How it was checked

  • go test ./internal/tui2/prose -run TestABareNumberedReplyStillDraws -v — new test, fails on the base commit ("32." rendered to nothing), passes with the fix.
  • go test ./internal/tui2/prose — full package green.
  • go vet ./internal/tui2/prose — clean.
  • go build ./... — whole tree builds.
  • Rendered-output check: 32. → [32.] at column 0; 1. one → [1. one]; 1. one\n2. two → two list rows; 32 → [32]. Markers for real lists are unchanged.
  • go run ./cmd/codeaf-changes check — 12 entries, all well formed.

Note: internal/namelaw's ## The name section test and internal/tui3's TestAConversationWithNoTitleIsNamedInWordsNotHex fail on a clean checkout of the base too, so they are pre-existing and unrelated to this change.

Checklist

  • A change entry — docs/changes/unreleased/1072-bare-number-reply-draws.md.
  • The manual knows about it — no slash command, key, tool, default, limit or refusal moved; this is a rendering fix, so no manual change is required. Grepped the chat corpus for a page claiming bare numbers do not render; none exists.
  • No new line in .github/known-red.txt.
  • Only my own paths are staged — render.go, the new test, and the change entry.

Closes #1072.

…t-Field#1072)

A model reply whose whole text was a number and a full stop (32., 1024.)
parsed as a Markdown ordered list with one empty item. renderer.list drew
the marker column, found no body, and popped the item as undrawn, taking
the marker with it, so the reply rendered to zero rows and the deck
skipped it. Draw the marker as literal text when the item body produced
nothing, which is the only case a bare <number>. reaches.
@7vignesh

7vignesh commented Oct 6, 2026

Copy link
Copy Markdown
Contributor Author

@santoshkumarradha pls review

Copy link
Copy Markdown
Member

Hey @7vignesh, thanks for the PR. Could you sign the CLA when you get a chance so we can review it?

https://cla-assistant.io/Agent-Field/CodeAF?pullRequest=1746

@7vignesh

7vignesh commented Oct 8, 2026

Copy link
Copy Markdown
Contributor Author

Hey @7vignesh, thanks for the PR. Could you sign the CLA when you get a chance so we can review it?

https://cla-assistant.io/Agent-Field/CodeAF?pullRequest=1746

done

Comment thread docs/changes/unreleased/1072-bare-number-reply-draws.md Outdated
Comment thread internal/tui2/prose/bare_number_test.go Outdated
- Rename change entry to 1746-... and set pr: 1746 (was the issue number).
- Assert the exact rendered output ('32.', '1024.', '1. one') instead of
  just non-empty.
@7vignesh

7vignesh commented Oct 8, 2026

Copy link
Copy Markdown
Contributor Author

Thanks @ZeroPoint95. Both addressed in the latest push:

  • Renamed the change entry to 1746-bare-number-reply-draws.md and set pr: 1746.
  • The test now asserts the exact rendered output ("32.", "1024.", "1. one") instead of just non-empty.

@ZeroPoint95
ZeroPoint95 merged commit 15edceb into Agent-Field:dev Oct 8, 2026
6 checks passed
@ZeroPoint95

Copy link
Copy Markdown
Collaborator

Merged. Thanks for the contribution @7vignesh!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

tui3: a reply that is only a number and a full stop draws nothing

3 participants