LearnNewsExamplesServices
Frontmatter
id8849
titleFix VDOM Teleportation Regression: Restore Window Context in updateBatch
stateClosed
labels
bugairegressioncore
assigneestobiu
createdAtJan 21, 2026, 1:27 PM
updatedAtJan 21, 2026, 1:39 PM
githubUrlhttps://github.com/neomjs/neo/issues/8849
authortobiu
commentsCount1
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJan 21, 2026, 1:39 PM

Fix VDOM Teleportation Regression: Restore Window Context in updateBatch

Closed v11.23.0 bugairegressioncore
tobiu
tobiu commented on Jan 21, 2026, 1:27 PM

The recent refactoring for Batched Disjoint VDOM Updates (Teleportation) in src/mixin/VdomLifecycle.mjs inadvertently removed the logic that attaches appName and windowId to the VDOM update payload.

This metadata is critical for Neo.worker.mixin.RemoteMethodAccess to correctly route messages in SharedWorker environments, particularly when multiple windows (Main Threads) are connected to the same App Worker.

Symptom: Operations that involve moving components between windows (e.g., LivePreview popping out to a new window) fail to update the VDOM/DOM in the target window because the VDOM worker cannot route the reply correctly or the message channel context is lost.

Cause: executeVdomUpdate constructs a batchData object but fails to check currentWorker.isSharedWorker and attach the window context before calling Neo.vdom.Helper.updateBatch.

Fix: Restore the SharedWorker check and context assignment in executeVdomUpdate.

tobiu added the bug label on Jan 21, 2026, 1:27 PM
tobiu added the ai label on Jan 21, 2026, 1:27 PM
tobiu added the regression label on Jan 21, 2026, 1:27 PM
tobiu added the core label on Jan 21, 2026, 1:27 PM
tobiu referenced in commit 1ccd84a - "fix(VdomLifecycle): Restore windowId context in updateBatch for SharedWorkers (#8849)" on Jan 21, 2026, 1:38 PM
tobiu assigned to @tobiu on Jan 21, 2026, 1:38 PM
tobiu
tobiu Jan 21, 2026, 1:39 PM

Input from Gemini 3 Pro:

✦ ✦ Fixed regression in src/mixin/VdomLifecycle.mjs.

Changes:

  1. Restored the currentWorker.isSharedWorker check in executeVdomUpdate.
  2. Injected appName and windowId into the updateBatch payload when running in a SharedWorker.
  3. Added a strong, intent-driven comment explaining why this block is critical for RemoteMethodAccess routing and multi-window operations.

This restores the ability for the VDOM worker to correctly route update replies to the originating window in a SharedWorker environment.

tobiu closed this issue on Jan 21, 2026, 1:39 PM