fix(mobile): throttle streaming thread visit updates - #9931
Conversation
|
Macroscope has since reviewed this pull request. An earlier review was skipped by a cost limit; a review has now completed, so that notice no longer applies. |
3ffe845 to
9d459a6
Compare
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — The mobile change is a narrowly scoped fix that throttles redundant streaming visit writes while preserving newest-watermark, navigation, and completion semantics. The accompanying server change is test-only, with no production runtime impact. You can add or adjust custom eligibility rules. Learn more. |
There was a problem hiding this comment.
reviewed diff and relevant surrounding code at 5c4609f5eb0948f5c5e6c1d61834e240b958eee3. no blocking findings.
the effect keeps a trailing newest watermark, bypasses the throttle for unseen completion/thread changes, and cancels pending work when content hides. isolated execution of the actual effect callback passed initial dispatch, trailing update, completion, thread switch, hidden cleanup and dedupe checks with mocked clock/command. no code changes needed. this was not a mounted react or native-device test.
ci snapshot: no failing or pending checks; some checks are skipped. this is a comment review, not an approval or merge.
9242b91 to
3d81172
Compare
Bugbot is paused — on-demand spend limit reachedBugbot uses usage-based billing for this team and has hit its on-demand spend limit. A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue. |
Dismissing prior approval to re-evaluate 53e0828
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
- Re-route steering that races completion into idempotent follow-up dispatches - Preserve scheduled-task attribution and provider ownership history across clients
Port main's pull-request discovery, active thread ordering, async question dismissal, settlement fixes, provider-session import, attachment context, and provider correctness changes into orchestration v2. Keep the branch's intentional composer and subagent behavior while adopting main's web and mobile fixes. Prevent headless setup terminals from hanging on the color probe, and move the v2 migration block to 050-061 after main claimed 048-049.
Restore the failed-before-start timer guard, align two server fixtures with the reconciled behavior, and remove dead files, exports, and dependencies surfaced by Knip. Drop the temporary branch push trigger now that the PR is mergeable, so each update runs the pull-request workflow once.
Keep main's batch machine-update banner and update action while preserving the v2 runtime-based environment lock used by draft load balancing.
Adopt TypeScript 7 and Effect rc.112 across orchestration v2, including the TaggedError API migration and updated Effect-aware tests. Restore main's composer-aware scroll-to-end clearance while retaining selected-model settings sync, preview recording transfer, image galleries, desktop context menus, and layout hit targets. Regenerate the lockfile on the upgraded dependency baseline.
efd9994 to
6102d00
Compare
Advertise bounded socket snapshots and authoritative dispatch validation, omit raw command output and inline file bodies at the wire boundary, and preserve compact status metadata across web and mobile. Add transport-budget coverage for snapshots, resume, commands, legacy import, and projection maintenance.
Restore pinned-thread shelf classification, server-owned unread state, hidden-subagent-safe project ordering, guarded jump hints, draft upload cleanup, and active-provider archive guards across the current and legacy sidebars. Bring the surrounding current-main sidebar work forward as well: canonical project favicons, stable row layout, thread file drops, account-aware mobile provider badges, and deferred desktop keyring loading.
53e0828 to
3b17e21
Compare
Bugbot is paused — on-demand spend limit reachedBugbot uses usage-based billing for this team and has hit its on-demand spend limit. A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue. |
8187b17 to
ada72ce
Compare
Streaming thread updates sent one visit command per watermark from React Native. Apply the web client's ten-second trailing throttle, retaining the newest watermark. Thread navigation and unseen completion still dispatch immediately; hidden content and selection cleanup cancel scheduled sends.
Rebuilt head
3b17e2142includes current V23aa47e294and test-only prerequisite #10865 (merge first). Feature remains one file, 27 additions and 6 deletions. Mobile typecheck, targeted lint and formatting pass. No new simulator run was performed; the prior measured UI evidence below is historical and bound to its stated revisions. CI pending. Direct Claude Opus 5 high review remains unavailable due to expired OAuth (exit 1 before inference).Historical simulator measurements and recordings
Measured at persisted
thread.visitedevents on one isolated iPhone 16 Pro simulator (iOS 26.5), with one burst per revision: 20 realthread.metadata.updatecommands at approximately 250 ms intervals over five seconds. Both runs used the same visible thread and disposable V2 server.ThreadDetailScreen.tsxfromb9fa1399c)9d459a6bb, integrated atfa6a1ab04)This measures write volume and dispatch spacing, not rendering speed. Title updates provide a controlled source of
updatedAtchanges; this was not a timed provider-token stream. The shared native Debug build exited 0; only the JavaScript bundle changed. The integrated candidate also includes #9929, explaining the visible file chip in the after recording.Before: clean recording · Before: annotated recording
After: clean recording · After: annotated recording
Recordings preserve original timing (before 29.53 s; after 53.63 s), with no idle trimming or speed changes. Captions report the stored-event measurements; the videos do not display a request counter. These caption-only recordings were visually inspected; the interaction-packet validator requires tap/swipe events and was not applicable.
Before/after stills
React Native typecheck and targeted lint passed in frozen integration verification. Android was not separately exercised. Targets Julius’s Orchestrator V2 branch in #2829; this changes only React Native.
A direct Claude Opus 5 high review attempt exited 1 because OAuth expired before model execution; no Claude review occurred. Implemented and verified with GPT-6 in Codex/T3.
Targets V2 #2829. Updated with GPT-6 in Codex/T3.