Make WordPress Core

Opened 13 months ago

Closed 12 months ago

Last modified 6 months ago

#52031 closed defect (bug) (reported-upstream)

Error when clicking Convert to regular blocks

Reported by: jeffabailey Owned by:
Milestone: Priority: normal
Severity: blocker Version: 5.6
Component: Editor Keywords:
Focuses: javascript Cc:


When clicking Convert to regular blocks with a reusable block an error occurs.

This happens within the latest Firefox and Chrome browsers.

WordPress Version: 5.6
Current WordPress Theme: Ryan Pro version 1.3.15
Theme Author: ThinkUpThemes - https://www.thinkupthemes.com
Theme URI: https://www.thinkupthemes.com/themes/ryan/
PHP Version: 7.3.7

See this screenshot for context: https://1drv.ms/u/s!AuD4G8fUTARZgbG3btn_datyyOuute4?e=nt1SBu

Uncaught (in promise) TypeError: e.substr is not a function

b https://jeffbailey.us/wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
p https://jeffbailey.us/wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
s https://jeffbailey.us/wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
Yr https://jeffbailey.us/wp-includes/js/dist/blocks.min.js?ver=65abb57f00d1d2ab3d3b16331cbbf560:3
CONVERT_BLOCK_TO_STATIC https://jeffbailey.us/wp-includes/js/dist/reusable-blocks.min.js?ver=d969baba471ea99a0d94fb9fd94d284c:2
Redux 9
V https://jeffbailey.us/wp-includes/js/dist/data.min.js?ver=777f925bfe1a2aea2a86b7b9ae6aed25:2
F https://jeffbailey.us/wp-includes/js/dist/data.min.js?ver=777f925bfe1a2aea2a86b7b9ae6aed25:2
p https://jeffbailey.us/wp-includes/js/dist/data.min.js?ver=777f925bfe1a2aea2a86b7b9ae6aed25:2
onClick https://jeffbailey.us/wp-includes/js/dist/block-library.min.js?ver=f57ef2e7b4eafc2e0c68f14376de3b1f:38
B https://jeffbailey.us/wp-includes/js/dist/components.min.js?ver=df4b16e21104c0e1043e9c0a0eeedd94:7
P https://jeffbailey.us/wp-includes/js/dist/components.min.js?ver=df4b16e21104c0e1043e9c0a0eeedd94:7
ki https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:176
ji https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:13
mi https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:13
lf https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:13
wi https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:187
Kd https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:32
pc https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:32
Wf https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:34
<anonymous> https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:236
uf https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:15
Qd https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:42
sc https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:41
unstable_runWithPriority https://jeffbailey.us/wp-includes/js/dist/vendor/react.min.js?ver=16.13.1:25
Da https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:60
<anonymous> https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:236
Ei https://jeffbailey.us/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:41


Change History (19)

#1 @desrosj
13 months ago

#52033 was marked as a duplicate.

#2 @alltha8matters
13 months ago

  • Focuses accessibility added
  • Version set to 5.6

Same problem I am also facing after 5.6 update.

I have a reusable blocks. After adding them into the post I cannot convert them to regular blocks. The new convert to regular block button is not working.

Last edited 13 months ago by alltha8matters (previous) (diff)

This ticket was mentioned in Slack in #accessibility by ryokuhi. View the logs.

13 months ago

#4 @ryokuhi
13 months ago

  • Focuses javascript added; accessibility removed

Hello @jeffabailey, welcome on Trac and thanks for reporting this issue!
It was discussed today during the weekly accessibility team's bug scrub.
We are removing the accessibility focus, as this doesn't seem to be an accessibility issue.
Feel free to add the label again if you think that our team can help in solving the issue!

#5 @alltha8matters
13 months ago

Please update on resolving the issue

This ticket was mentioned in Slack in #core by lukecarbis. View the logs.

13 months ago

#7 @lukecarbis
13 months ago

@jeffabailey Thanks for reporting the problem! I tried replicating the problem, but the "Convert to regular blocks" button worked fine for me. Does the issue still happen with all plugins disabled and a default theme (Twenty Twenty-One) activated?

If so, could you share the reusable block that is causing the problem?

#8 @jeffabailey
13 months ago

Hello, I switched the theme to Twenty Twenty-One and tried to convert the reusable block, and the same error occurred.

I saved a new reusable block with just a paragraph, and that worked fine.

I then removed the Ultimate Blocks -> Table of Contents block from my reusable block and saved it. I was then able to use the reusable block without issue.

It appears that the issue has been isolated to the Ultimate Blocks -> Table of Contents block.


#10 @hellofromTonya
13 months ago

  • Component changed from General to Editor
  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Hello @jeffabailey,

As you note, the issue is:

isolated to the Ultimate Blocks -> Table of Contents block.

I'd suggest contacting the plugins' Support forum to report the issue with the plugin's block.

I'm going to close this ticket as the issue is isolated to a plugin rather than Core. However, after contacting the plugin's support, if the issue appears to be due to Core, please reopen.

#11 @alltha8matters
13 months ago

  • Resolution invalid deleted
  • Status changed from closed to reopened


Its not just related to a specific plugin.
I am using generate blocks and created a reusable blocks through it.

Now if I add that reusable block inside post and clicked on convert to regular block, the block does not get converted to regular.. It stays in reusable condition.

#12 @alltha8matters
13 months ago

Looks like the issue may not be for new WordPress installers. but since we have updated WordPress from the previous version, few of the users are facing this converting to regular blocks issue

#13 @alexius08
13 months ago

Hi @alltha8matters! I'm from the Ultimate Blocks dev team. In our case, the block in question isn't designed to be used as a reusable block. Have you checked it yourself or asked the Generate Blocks dev team if the block you're trying to use doesn't depend on inputs beyond the block's control (e.g. in our case, existing Heading blocks within the page)?

#14 @jeffabailey
13 months ago


It was working fine before the latest version of WordPress.

I understand why it wouldn't work, though. It appears we need WordPress block "templates" rather than reusable blocks, though I could be missing a plugin/feature to handle this.

#15 @rgires
12 months ago

Hi @jeffabailey, @alexius08

I am on the versions

  • wordpress 5.6
  • ultimate-addons-for-gutenberg.1.20.1.zip
  • firefox 84.0.2 (64 bits)

and it always has this javascript error when converting a reusable block into a regular block

if I delete the 'Advanced Table' block, it works
there was no problem in the previous version of WP 5.5.xxx

error JS

Uncaught (in promise) TypeError: e.substr is not a function

b /wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
p /wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
s /wp-includes/js/dist/block-serialization-default-parser.min.js?ver=1768ef183a4597932a52df4c355129c1:2
Yr /wp-includes/js/dist/blocks.min.js?ver=65abb57f00d1d2ab3d3b16331cbbf560:3
CONVERT_BLOCK_TO_STATIC /wp-includes/js/dist/reusable-blocks.min.js?ver=d969baba471ea99a0d94fb9fd94d284c:2
e Redux

Do you have a solution?
best regard

#17 @talldanwp
12 months ago

  • Resolution set to reported-upstream
  • Status changed from reopened to closed

This was reported in the Gutenberg repo where it's being tracked, so closing this trac ticket:

Block editor related issues should ideally be created there instead of in trac, but thanks for flagging the bug.

Last edited 12 months ago by talldanwp (previous) (diff)

#18 follow-up: @rgires
12 months ago

I found another plugin that works very well
it makes the same kind of HTML table in color and converts correctly
getwid - https://wordpress.org/plugins/getwid/
best regard

#19 in reply to: ↑ 18 @jeffabailey
12 months ago

Replying to rgires:

I found another plugin that works very well
it makes the same kind of HTML table in color and converts correctly
getwid - https://wordpress.org/plugins/getwid/
best regard

👍, Thanks for trying but I still can't convert my block when using the getwid table of contents block.

Last edited 12 months ago by jeffabailey (previous) (diff)
Note: See TracTickets for help on using tickets.