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 — Android: tapping a chat in the thread list waits ~350 ms on the JS thread before the screen opens · Issue #40941 · pingdotgg/t3code

Android: tapping a chat in the thread list waits ~350 ms on the JS thread before the screen opens #40941

New issue
Copy link
New issue
Copy link
Open
Open
Android: tapping a chat in the thread list waits ~350 ms on the JS thread before the screen opens#40941
Copy link
Labels
via-triageFiled through npx t3 triage

Description

@zakius
zakius
opened on Nov 22, 2026
Issue body actions

What happened

On Android, opening a chat from the home thread list feels unresponsive. Nothing happens on screen for about a third of a second after the finger lifts. Then the push animation plays, and the chat is often still blank for a moment. The back arrow, the bottom tab bar, Search and the Settings pages feel fine. The user describes it as "it waits 300 ms longer after the tap than tap vs hold vs double tap requires".

Diagnosis

The delay is JS work that runs before the native-stack transition can start. It is not gesture arbitration or the network.

  • A fixed cost on every open. After a tap on a chat row, the JS thread (mqt_v_js) is about 100% busy for roughly 500–700 ms. A 6-message chat costs about the same as a 705-message chat.
  • The new-thread draft screen costs the same. Its first 0.7 s also takes 690–720 ms of JS, and it has no messages. So most of the cost is in what the Thread route and the new-thread draft route share: the detail screen scaffolding and the composer.
  • Other pushes are cheap. Search costs 50–90 ms and Settings → General / Appearance costs 120–210 ms. The app idles at 1–7% JS.
  • Feed work comes on top. Larger chats keep the JS thread busy for another 0.4–1.3 s after the transition. Meanwhile ThreadFeed keeps the list at opacity: 0 while settling (~3854 / ~4390, with a 1000 ms fallback), which is the blank period.
  • No feedback during the wait. RowPressable shows its overlay only on hover, so a finger press gets no highlight.

Forcing the app locale to en-US (the device is pl-PL, which falls back to en) did not change the cost meaningfully: 510–620 ms against 510–710 ms.

Nothing was profiled. The release build is not profileable. The fix hints below come from reading the source at dd941b9, ranked by likely impact:

  1. Intl polyfill work in gt() / ICU formatting. Open PR perf(mobile): memoize Intl polyfills used during thread opens #40602 profiled this as the dominant JS cost of thread opens on another Android device. The detail screen and the composer call gt()/m() many times on mount, so this fits a cost that is the same for every chat. Landing perf(mobile): memoize Intl polyfills used during thread opens #40602, and perf(mobile): cache markdown AST/transforms and render-1 link URLs #40603 for markdown, is probably the biggest single win.
  2. Mount the heavy detail body after the transition. ThreadScreenHost.tsx:64-71 publishes props from a useLayoutEffect with no dependency array into a useSyncExternalStore outlet. Both ThreadRouteScreen and NewTaskDraftScreen use it. This forces a second synchronous render of ThreadDetailScreen + ThreadComposer inside the tap's task. The app already has a pattern for deferring until transitionEnd: usePullRequestDiffEntry in features/pull-requests/usePullRequestDiff.ts:71-109. Rendering a light shell first, or publishing through startTransition, would let the slide start right away.
  3. Composer derivations on every render. ThreadComposer.tsx:418 / :602 call buildModelOptions, which is O(providers × models), and serverConfigForCwd(...) likely returns a fresh object, which defeats React Compiler memoization. Caching by serverConfig identity would avoid both.
  4. A screen flag that may not be needed on Android. index.ts:16 turns on synchronousScreenUpdatesEnabled globally, and its comment says it is for iOS FormSheet sizing. Gate it to iOS and re-measure on Android.
  5. First open per session. AdaptiveWorkspaceLayout.tsx:575 sets setFileInspectorPreferredVisible(false) when the initial value is true. This re-renders the home list in the same batch.
  6. Feed. Seed estimatedListSize from the window dimensions, because viewportHeight starts at 0 on phones (~3216 / ~4435). Also consider building the feed after the transition.

Steps to reproduce

  1. On an Android phone, open the T3 Code app on the Chats tab.
  2. Tap any chat row, even one with a handful of messages.
  3. Nothing moves for about 350 ms after release. Then the push starts, and the feed is often blank for a further 0.1–1 s.
  4. Compare with Search, a Settings page, the back arrow or the bottom tabs. All of them react quickly.

Version

Android app 2.3.0 (versionCode 809), production package com.t3tools.t3code. Server 0.1.12-nightly.20261121.5051.

Environment

ASUS Zenfone 10 (ASUS_AI2302), Android 15, system locale pl-PL. The connection to the server ran over T3 Connect. System animator scale 0.5, transition scale 0.

Evidence

Screen recordings with Android's pointer-location overlay, timed from finger release to the first screen change. The taps were 110 ms presses injected with adb shell input swipe, some with an 8 px drift. Drift made no difference.

Interaction Response after release
Chat row (4 runs) 353, 334, 352, 403 ms
Back arrow in chat (4 runs) 117, 118, 151, 101 ms
Bottom tabs (4 runs) 152, 84, 166, 117 ms

JS-thread CPU (mqt_v_js, from /proc/<pid>/task/<tid>/stat) in the first 0.7 s after a tap:

Screen opened JS busy
Chat, 6 messages 570–720 ms
Chat, 198 messages 580–710 ms
Chat, 705 messages 680–710 ms
New-thread draft 690–720 ms
Search 50–90 ms
Settings → General 120–140 ms
Settings → Appearance 200–210 ms
Idle on home list 10–75 ms per 1 s

Over 40 s of normal use, dumpsys gfxinfo reported 493 frames: p50 8 ms, p90 21 ms, p99 38 ms, and "Number High input latency: 650".

Related issues

  • perf(mobile): memoize Intl polyfills used during thread opens #40602 (open PR): memoizes Intl polyfills during thread opens. Its profile matches these symptoms, and this report is independent evidence for it from a second Android device.
  • perf(mobile): cache markdown AST/transforms and render-1 link URLs #40603 (open PR): caches markdown parses.
  • [Bug]: Mobile: opening a thread shows a blank view for 5+ s ("Loading messages..." then "Syncing messages...") even on fast Wi-Fi #24192 and [Bug]: With ~80 concurrent runs the server's one event-loop core saturates; opening a thread takes 2–3 min and the client re-subscribes every ~65 s #38646 (closed): server-side causes of slow opens. Not this.

Fix applied or workaround

None on the client. The server was healthy when these measurements were taken.

Filed by

Claude Opus 5.5 (claude-opus-5-5) in Claude Code, via T3 Code triage.

Activity

  1. zakius
    added
    via-triageFiled through npx t3 triage
    on Nov 22, 2026
  2. juliusmarminge
    added a commit that references this issue on Nov 22, 2026

    perf(mobile): a chat starts opening before its detail screen renders

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    via-triageFiled through npx t3 triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      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.