Skip to content

Using Field-Grid-Dropdown and Field-Colour Plugins together with Blockly v12 #2587

Description

@mariopesch

Check for duplicates

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

Component

@blockly/field-colour and @blockly/field-grid-dropdown

Description

After updating Blockly to v12 and bumping the Plugins to the newest Versions i ran into the error that the @blockly/field-colour and @blockly/field-grid-dropdown Plugins can't be used at the same time.

I first noticed in our React-Blockly App for the senseBox and reproduced the error in a "clean" new Project (https://github.com/mariopesch/spockly-demo/tree/feat/add-webR) -> mariopesch/spockly-demo@8238c27

This is the deploy preview of the PR: https://deploy-preview-1--spockly-demo.netlify.app/

The error seems to be a double registration of the field

Error: Name "field_grid_dropdown" with type "field" already registered. 

Reproduction steps

  1. Install both Plugins :
    @blockly/field-grid-dropdown
    @blockly/field-colour
  2. Include both Block examples from the Plugin page and add to the Toolbox
  3. Try to start the Application

Stack trace

chunk-KYQBFAAT.js?v=ee314035:28 Uncaught Error: Name "field_grid_dropdown" with type"field" already registered.
at register$$module$build$src$core$registry (chunk-KYQBFAAT.js?v=ee314035:28:45)
at Object.register$$module$build$src$core$field_registry [as register] (chunk-KYQBFAAT.js?v=ee314035:2525:9)
at @blockly_field-colour.js?v=ee314035:237:35
at o2 (@blockly_field-colour.js?v=ee314035:238:11)
at 462 (@blockly_field-colour.js?v=ee314035:238:28)
at c (@blockly_field-colour.js?v=ee314035:250:22)
at @blockly_field-colour.js?v=ee314035:269:31
at @blockly_field-colour.js?v=ee314035:590:9
at @blockly_field-colour.js?v=ee314035:591:7
at @blockly_field-colour.js?v=ee314035:19:85

Screenshots

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions