Google Docs ka Jhol
Pasting Gemini transcripts into Google Docs injects hidden iFrames that cause a fatal MobX state tree detached-node exception. The sanitization script physically removes the DOM elements but fails to detach them from the state tree, causing the sync engine to crash when it encounters the phantom node.
Web Browser
The text should paste and sync successfully.
The Architectural Root Cause (MobX State Tree Crash)
Google Docs operates on a strict state manager called MobX State Tree. Every data piece and UI element is tracked as an active node. Reading or writing to a detached "ghost" node triggers an immediate fatal application exception.
When you copy a Gemini transcript, it unpacks into three distinct layers: 1. Raw Text 2. Hidden HTML iFrames 3. DOM Snapshots
The Race Condition: When pasted, Google Docs intercepts the payload. A sanitization script attempts to strip incompatible HTML (the iFrames) while the state engine simultaneously tracks new metadata. The sanitization script physically destroys the DOM elements but fails to send a detach command to the MobX state tree.
The Crash: The "anonymous model" node becomes a phantom. When the Google Docs sync engine sweeps the state tree to push changes to the cloud, it attempts to query the phantom node (for ID, tabID, added_at). This triggers a fatal MobX exception, shattering the sync engine.
Service Worker Cascade:
The crash interrupts the client-side JavaScript execution, leaving the service worker (sw.js) waiting on a promise for navigation preload. The service worker eventually cancels the connection, dropping the app offline.
The Fix:
1. Sanitization: Explicitly call the detach method on the anonymous model nodes before the browser's garbage collector unmounts them from the DOM.
2. Service Worker: Wrap the preload request inside an event.waitUntil() or respondWith() function so the promise settles independently of the main client thread.
- Generate meeting notes in Google Meet using Gemini.
- Copy the generated notes.
- Paste them into an existing Google Doc.
- Observe the 'Can't sync your changes' error and document freeze.
Watch the Full Breakdown
7-minute technical deep dive with live console analysis
โถ Watch on YouTubeJoin the BIB Community
Get access to the full vault: raw console logs, repro steps, QA sandbox, and community Q&A.
Join 200+ QA Engineers & Developers
Join โ It's Free Request Episode Access- Episode
- S01E01
- Software
- Google Docs / Gemini
- Vendor
- Unresolved
- Vibe
- Hilarious