GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(mobile): untitled subagent rows no longer end in a broken character by spoukyii · Pull Request #30373 · pingdotgg/t3code

Conversation

@spoukyii

@spoukyii spoukyii commented Nov 3, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Problem

Mobile's Agents sheet titles a subagent that has no title of its own from its prompt, in rowTitle in apps/mobile/src/features/threads/threadAgentsPresentation.ts. A prompt longer than 80 UTF-16 code units is cut at 77 units and gets .... When an emoji straddles that cut, the slice keeps only the emoji's high surrogate (U+D83D for 😀). The title then ends in a replacement character (�) right before the ..., where it should end on the last whole character before the emoji.

Where the broken end shows:

  • The Stop confirmation dialog, whose message is Stop <title>?.
  • The Stop button's VoiceOver label, Stop agent <title>.

The row in the sheet uses the same title, but it is one line shared with the status, the elapsed time and the Stop button. On a phone it cuts the title off with … well before the 77th unit, so the row looks the same before and after this fix. Rows of subagents that have a title, workflow member rows (built with an empty prompt) and the workflow Stop dialog (which names the workflow) are not affected. This PR changes mobile only.

Expected: the cut never splits a surrogate pair, as #29163 and #29563 do for thread titles.

Change

When the cut would land between a high and a low surrogate, it steps back one unit. That is the check #29563 added to t3 thread start titles and #29163 added to create_threads titles. The 80-unit limit, the ... suffix and every title without a split emoji are unchanged.

Scope and approval

This is a very small, focused fix for an obvious bug. It is the defect #29563 ("t3 thread start titles no longer end in a broken character") and #29163 ("create_threads titles no longer end in a broken character") fixed in the server's title copies, still present in mobile's own title cut for untitled subagents. It applies their check and changes no other behaviour, setting or contract.

packages/client-runtime/src/state/subagentRuntime.ts:205 has a separate copy of the same cut (80-unit limit, cut at 77, ...) for the runtime subagent title. Web's thread relationships control falls back to it when a subagent's thread has no title, and mobile builds its workflow groups from the same runtime list. I have not confirmed where that cut title shows. I kept it out of this PR so each PR fixes one site, as #29158, #29163 and #29563 did. No open PR changes that cut.

Overlap check, by rowTitle, threadAgentsPresentation and by file. #24968, #27189 and #30249 change threadAgentsPresentation.ts, but none touches rowTitle. #30249's hunk at lines 48 to 54 sits just above it. #24968 also rewrites the test file whole. #24611 changes the shared truncate, which this function does not call.

Verification

apps/mobile/src/features/threads/threadAgentsPresentation.test.ts gets one assertion in its existing falls back to a trimmed prompt when the agent has no title case. It titles a prompt of 76 xs followed by 😀, so the emoji sits on the cut.

On main with only the test commit (e4b3bbd), from apps/mobile, vp test run src/features/threads/threadAgentsPresentation.test.ts:

 FAIL  |unit| src/features/threads/threadAgentsPresentation.test.ts > resolveSubagentRowPresentation > falls back to a trimmed prompt when the agent has no title
Expected: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx..."
Received: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx�..."
      Tests  1 failed | 26 passed (27)

The � in Received is the lone high surrogate U+D83D.

With the fix:

  • vp test run src/features/threads/threadAgentsPresentation.test.ts in apps/mobile: 27 tests passed.
  • vp run check:changed from the repo root: format, lint, knip, typecheck (2 packages), tests (2 files) and the React Compiler check all pass.

To see it in the app: on mobile, open a thread where the agent started a subagent that has no title, with a prompt of 76 ASCII characters followed by an emoji and more text. While it runs, tap the agents segment of the floating control above the composer to open the Agents sheet, then tap the subagent's Stop button. On main the dialog's Stop <title>? message has the title end in a replacement character and then .... With the fix it ends on the last ASCII character and then .... VoiceOver reads the Stop button's label the same way.

What I could not check: the dialog on a device, or which providers report a subagent with no title. The test covers the row presentation function the dialog and the label read. Like #29163 and #29563, the cut works per code point, so it can still split a grapheme cluster such as a flag, a skin-tone modifier or a ZWJ sequence; it never leaves a lone surrogate. Hermes has no Intl.Segmenter, so a grapheme-aware cut is not available on mobile without a new dependency.

Bug: an untitled subagent row on mobile ends in a broken character when an emoji sits at the cut

This was written with Claude Opus 5.5 in Claude Code, driven from T3 Code.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
spoukyii added 2 commits November 3, 2026 12:54
@spoukyii
test(mobile): cover a long untitled subagent prompt that ends on an e…
e4b3bbd
…moji
@spoukyii
fix(mobile): untitled subagent rows no longer end in a broken character
5a89ae6
The Agents sheet titles a subagent that has no title of its own from its
prompt, cut at 77 UTF-16 code units with "..." added. When an emoji
straddled the cut, the title kept only its high surrogate and ended in a
replacement character before the "...". The row itself is one line and
cuts the title off well before that point, but the Stop confirmation
dialog ("Stop <title>?") and the Stop button's VoiceOver label show the
whole title.

The cut now steps back one unit when it would land between a high and a
low surrogate, the same check pingdotgg#29163 and pingdotgg#29563 added to thread titles.

Bug: an untitled subagent row on mobile ends in a broken character when an emoji sits at the cut
@github-actions github-actions Bot added the vouch:unvouched Author is not yet trusted in the VOUCHED list. label Nov 3, 2026
macroscopeapp[bot]
macroscopeapp Bot approved these changes Nov 3, 2026
View reviewed changes
@macroscopeapp

macroscopeapp Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at 5a89ae6

Macroscope's review found this PR approvable — Long prompt-derived subagent titles now truncate without splitting a Unicode surrogate pair. The change is limited to presentation text and leaves agent execution and stored data unchanged.

You can add or adjust custom eligibility rules. Learn more.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot added the size:S 10-29 changed lines (additions + deletions). label Nov 3, 2026
@coderabbitai

coderabbitai Bot commented Nov 3, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Walkthrough

rowTitle now avoids splitting a UTF-16 surrogate pair when it truncates a long prompt. A test covers the boundary behavior with an emoji-containing prompt.

Changes: Mobile thread title truncation

Layer / File(s) Summary
Surrogate-safe title truncation
apps/mobile/src/features/threads/threadAgentsPresentation.ts, apps/mobile/src/features/threads/threadAgentsPresentation.test.ts
rowTitle keeps the 80-code-unit limit and ellipsis. When the cut would split a surrogate pair, it moves the boundary back one code unit. The fallback-title test adds an emoji-containing prompt.

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Bug fix

Possibly related PRs

  • pingdotgg/t3code#30347: Both changes adjust mobile prompt-derived title truncation to avoid splitting an emoji surrogate pair.
  • pingdotgg/t3code#29906: Both changes adjust UTF-16 truncation for long subagent titles to preserve surrogate pairs.
  • pingdotgg/t3code#29563: Both changes prevent prompt-derived titles from splitting an emoji at an 80-unit UTF-16 boundary.

Suggested labels: bugfix, 📱 Native Change, size:S

Suggested reviewers: t3dotgg, bil0000

Merge Risk: Minimal · up to 5a89a

The mobile title truncation fix is mergeable; the reported replacement-character issue is covered by the updated implementation and test.

Pre-merge checks: Passed 4
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main mobile fix: preventing broken characters in untitled subagent rows.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description follows the template's Problem, Change, Scope and approval, and Verification sections, and it is detailed and specific. It explains the bug (a 77-unit cut that keeps a lone high surrog…
Full details: Description check

Explanation

The description follows the template's Problem, Change, Scope and approval, and Verification sections, and it is detailed and specific. It explains the bug (a 77-unit cut that keeps a lone high surrogate, shown as a replacement character before ...), the fix (step back one unit when the cut would split a surrogate pair), and the affected surfaces (Stop dialog and VoiceOver label). It cites the related fixes #29163 and #29563 and names the overlapping PRs. Verification includes a failing-then-passing test on main and the fixed branch, plus vp run check:changed. It also states what was not checked: the dialog on a device and which providers return untitled subagents. The Scope section argues the change qualifies as a very small, focused fix of an obvious bug. The description leaves out the template's before/after screenshots, but the change has no visual UI diff in the Stop dialog that could be captured easily, and the author describes the manual repro steps instead. The template's commit-title line is not present in the description body, but the PR title is outside this check's scope.

Finishing Touches
Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

CodeRabbit Verify

  • Run CodeRabbit Verify to test the changes in this pull request.
Recent review info
Run configuration
  • Source mode: Auto
  • Repository: pingdotgg/t3code
  • Branch: main
  • File: .coderabbit.config.ts
  • Commit: d1ec71e
  • Layers: Repository TS config
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 2c69e9cd-c18b-4049-bb8b-70f96e5f417c
Commits

Reviewing files that changed from the base of the PR and between d1ec71e and 5a89ae6.

Files selected for processing: 2
  • apps/mobile/src/features/threads/threadAgentsPresentation.test.ts
  • apps/mobile/src/features/threads/threadAgentsPresentation.ts

Limit details: You’ve used all 10 included reviews currently available.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@spoukyii spoukyii mentioned this pull request Nov 3, 2026
fix(client-runtime): untitled subagent titles no longer end in a broken character #30390
Merged
@coderabbitai coderabbitai Bot mentioned this pull request Nov 3, 2026
fix(client-runtime): subagent previews no longer end in a broken character #30391
Merged
@spoukyii

spoukyii commented Nov 6, 2026

Copy link
Copy Markdown
Contributor Author

Closing this. I couldn't run the mobile app on a device or emulator here, so the fix was only checked by its unit test. I'd rather not ask for a merge on that alone.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@spoukyii spoukyii closed this Nov 6, 2026
@tiliakoos tiliakoos mentioned this pull request Nov 23, 2026
fix(mobile): untitled subagent rows no longer end in a broken character #41609
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@macroscopeapp macroscopeapp[bot] macroscopeapp[bot] approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

size:S 10-29 changed lines (additions + deletions). vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@spoukyii
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.