8000 RangeError: Maximum call stack size exceeded when using FieldNumber or FieldTextInput due to recursive size_ setter · Issue #9055 · google/blockly · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
RangeError: Maximum call stack size exceeded when using FieldNumber or FieldTextInput due to recursive size_ setter #9055
Closed as not planned
@mikeharv

Description

@mikeharv

Check for duplicates

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

Description

Starting in Blockly 12.0.0-beta.6, using built-in fields like FieldNumber or FieldTextInput can result in a RangeError: Maximum call stack size exceeded.

This is caused by the the introduction of an accessor in the FieldInput class (#9011). While the code looks correct, when compiled with common tools (e.g. Webpack/Babel), the call to super.size_ = ... is sometimes transpiled to this.size_ = ..., causing infinite recursion at runtime. This affects any project that uses FieldNumber, FieldTextInput, or other FieldInput subclasses.

This is a bundler-sensitive issue triggered by the recent introduction of an accessor for size_.

Reproduction steps

  1. Use 12.0.0-beta.6
  2. Add any block with a FieldNumber or FieldTextInput

Stack trace

ncaught RangeError: Maximum call stack size exceeded
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)
    at _class4.set (field_input.ts:109:5)

Screenshots

Image Image

Browsers

No response

Metadata

Metadata

Assignees

Labels

issue: bugDescribes why the code or behaviour is wrong

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0