Skip to content

Uncaught runtime errors in Weave SDK 3.2.5 #992

@christianms-itx

Description

@christianms-itx

query_data.csv (Source)

Bug 1 — Uncaught TypeError: Cannot read properties of undefined (reading 'setAttrs') after exiting text-node edit mode

1,439 errors · 1 user · 1 session · ~1 hour of text-editing activity.

Uncaught TypeError: Cannot read properties of undefined (reading 'setAttrs')

Stack trace

at gn._batchChangeChild     (konva chunk, col 186354)
at gn.update                (konva chunk, col 186789)
at gn._fire                 (konva chunk, col 76097)
at gn._fireChangeEvent      (konva chunk, col 74098)
at gn._setAttr              (konva chunk, col 74803)
at t.setEnabledAnchors      (konva chunk, col 54641)
at t.enabledAnchors         (konva chunk, col 55503)
at Kn.handleBehaviors       (weave-sdk chunk, col 139721)
at Kn.setSelectedNodes      (weave-sdk chunk, col 140387)
at u.removeTextAreaDOM      (weave-sdk chunk, col 253427)

What we observe

Triggered when the user exits a text node edit (click outside or Escape). The sequence inside removeTextAreaDOM:

  1. updateNode is called — CRDT update completes successfully.
  2. selectionPlugin.setSelectedNodes([textNode]) is called to re-select the node.
  3. setSelectedNodeshandleBehaviors()this.tr.enabledAnchors([]) on the Konva Transformer.
  4. The Transformer iterates its children to propagate the change, but at least one anchor child is undefined, causing Konva to throw in _batchChangeChild.

The stale anchor reference does not appear to be cleaned up between successive edit cycles, so every subsequent text-edit exit reproduces the crash once the Transformer reaches this state.


Bug 2 — Uncaught TypeError: Cannot read properties of undefined (reading 'setAttrs') during pointer movement in image crop mode

736 errors · 1 user · 1 session · sub-second bursts (fires on every pointermove while crop mode is active).

Uncaught TypeError: Cannot read properties of undefined (reading 'setAttrs')

Stack trace

at gn._batchChangeChild             (konva chunk, col 186354)
at gn.update                        (konva chunk, col 186789)
at gn.forceUpdate                   (konva chunk, col 186307)
at t.drawGrid                       (weave-sdk chunk, col 262583)
at h                                (weave-sdk chunk, col 257772)
at Ft.<anonymous>                   (weave-sdk chunk, col 259750)
at Ft._fire                         (konva chunk, col 76097)
at Ft._pointermove                  (konva chunk, col 92600)
at content.addEventListener.passive (konva chunk, col 90163)

What we observe

Triggered on every pointer move while image crop mode is active:

  1. Stage _pointermove fires on each mouse movement.
  2. The crop mode's pointermove handler calls handleGriddrawGrid.
  3. drawGrid calls this.transformer?.forceUpdate() on the crop mode's internal Transformer.
  4. forceUpdateupdate()_batchChangeChild iterates the Transformer's children; at least one is undefined, causing the crash.

A single crop session generates hundreds of errors in seconds.


Bug 3 — Uncaught TypeError: e?.canDrag is not a function when dragging a canvas node

7 errors · 5 users · 6 sessions · different moodboards.

Uncaught TypeError: e?.canDrag is not a function

Stack trace

at As.<anonymous>       (weave-sdk chunk, col 157994)
at As._fire             (konva chunk, col 76097)
at As._fireAndBubble    (konva chunk, col 75259)
at Re._fireAndBubble    (konva chunk, col 75514)
at Re.fire              (konva chunk, col 70564)
at Re.startDrag         (konva chunk, col 76588)
at _drag                (konva chunk, col 51144)

What we observe

Triggered when starting to drag a canvas node. The dragstart handler (As.<anonymous>) calls e?.canDrag() on the drag target. The optional chaining resolves the property, but canDrag is not a function on that node at that moment — suggesting that under certain lifecycle conditions the target node does not have canDrag defined as a callable.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions