Skip to content

Recursive block selects firing with v12 #9087

@mikeharv

Description

@mikeharv

Check for duplicates

  • I have searched for similar issues before opening a new one.

Description

With v12.0.0, Blockly seems to be firing far more Blockly.Events.SELECTED events than normal. This is leading to performance issues.

Reproduction steps

  1. Visit any v12 demo page, such as https://google.github.io/blockly-samples/plugins/field-grid-dropdown/test/index.html
  2. Using the console, add a simple event listener to log block selection events. For example:
Blockly.getMainWorkspace().addChangeListener(e=>{if(e.type===Blockly.Events.SELECTED){console.log(e);}})
  1. Drag a block out of the toolbox and connect it to another block.
  2. Inspect the console. You will see over a dozen selection events.

This does not happen with v11, such as at https://blockly-demo.appspot.com/static/tests/playground.html

Stack trace

Screenshots

Image

Browsers

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    issue: bugDescribes why the code or behaviour is wrong

    Type

    No type

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions