Repository navigation
Fix Android reconnect toasts, cache state across suspend/resume, and fix 2 live phone crashes - #2344
Merged
trissim merged 1 commit intoNov 28, 2026
Conversation
…fix 2 live phone crashes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Fixes the Android minimize/reopen reconnect toasts, slow blank-screen reconnects, and two live Pixel 8a crashes pulled directly from device logs (
org.toadcomms.toadcommson 2026-11-27):Silence transient disconnect error toasts (
src/toad/client/connection.py,src/toad/client/application.py)ObservationFailureReport(MroDispatch)(connection.py) so expected remote transport drops (ConnectorObserverClosedwith non-ServiceFailedRelayEnding,OSErrorEOF) log quietly and auto-retry without poppingreport_fatal/show_errortoasts on every phone lock/unlock. Real Core service crashes (ServiceFailed) and local observer deaths (ObserverDied) still surface through the host.app.workspace_sessions.selected.reload()fromSuspendedPresence.activate(application.py:117-123) and madeCoordinationAccess.resume_routeunconditionally publishCoordinationObservedafterreopen_currentfinishes — eliminating theObserverRetirederror burst (Task-1811,Task-1654, etc.) wherereload()raced the dying observation on every resume.Keep cached state warm across same-root reconnects & brief Android app switches (
src/toad/client/connection.py,src/toad/client/sidebar_state.py,src/toad/qt/virtual_scroll.py)RemoteObserving.resumed_throughnow callsRemoteCoreConnection.resume_observe(access, self.served_root)when reconnecting to the same connection, skipping the coldCommsServedRootToolHTTPS round-trip on resume.CoordinationAccess.observe_remoteretains and reuses(SidebarModel, RegistryReads)perroot, andObservation.attachpreservesnotification_knownandthread_statuswhen reconnecting to the same bus root (only clearing them when switching to a different root).SidebarStateMachine.bind_observationskipsmodel_replaced()on same-root reconnects so the sidebar stays painted and diffs in place instead of flashing blank /"Reading comms"for ~3 s while the server spins up a new/observeworker.RowDocumentStore._application_state_changeddefersrelease_documents()by 60 s (SUSPEND_RELEASE_MS = 60_000) onApplicationSuspendedand cancels onApplicationActive, so brief app switches keep laid-outQTextDocuments and 3x DPRRowPicturestiles warm instead of taking a 100+ ms re-layout/re-rasterize stall on every unlock.Fix two live crashes from Pixel 8a
logs/errors/(src/toad/qt/transcript_history.py,src/toad/qt/history.py)QtTranscriptHistory.undrawnnow returnsnot self.draws_rows(matching Textual'sTranscriptHistory/HistoryPager.undrawn) instead of inheriting wire-onlyReadMarkedHistory.undrawn(page.after.requires_read()), which crashed withAttributeError: 'NoNativeTranscriptCursor' object has no attribute 'requires_read'on DM arrivals (History_2026-11-27T20_45_38).HistoryRowDelegate.prepare_inlinereturnsFalsewhenself._stoppedis True (and returnskey in self._prepared), eliminatingKeyErrorathistory.py:375when a stopped delegate lays out a late draft (Task-449_failed_2026-11-27T20_45_38).Verification
tools/qt_inherit_ratchet.py: 0 across all baselines (REL_IMPORTS=0).tests/model/test_android_resync_lazy_load_catchup.py,tests/model/test_android_perf_ux_arrivals.py,tests/textual/test_observation_shutdown.py,tests/textual/test_sidebar_failure_lifetime.py,tests/guards/test_shared_history_change.py,tests/guards/test_shared_hook_sequences.py.