Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Navigation Link Block: Crashes when you edit the title #29391

Closed
georgeh opened this issue Feb 26, 2021 · 3 comments · Fixed by #29608
Closed

Navigation Link Block: Crashes when you edit the title #29391

georgeh opened this issue Feb 26, 2021 · 3 comments · Fixed by #29608
Assignees
Labels
[Block] Navigation Affects the Navigation Block [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@georgeh
Copy link
Contributor

georgeh commented Feb 26, 2021

Description

The Navigation Link Block crashes when you attempt to edit the text of the block.

Step-by-step reproduction instructions

  1. Add a Navigation block
  2. Add a Link block
  3. Enter the URL https://example.com and press enter. The text of the block will change to "example.com"
  4. Click on the text so that the cursor is somewhere in the text field
  5. Press an arrow or letter key

Expected behaviour

The cursor should move or the letter should be inserted.

Actual behaviour

The block crashes.

Screenshots or screen recording (optional)

Screen.Recording.2021-02-26.at.4.37.53.PM.mov

WordPress information

  • WordPress version: 5.7-beta1-50237
  • Gutenberg version: master c993a8
  • Are all plugins except Gutenberg deactivated? Yes
  • Are you using a default theme (e.g. Twenty Twenty-One)? Yes

Device information

  • Device: Desktop
  • Operating system: macOS Big Sur
  • Browser: Reproduced in Chrome 88.0.4324.192 and Firefox Developer 87.0b2
@georgeh
Copy link
Contributor Author

georgeh commented Feb 26, 2021

This seems to predate the recently-landed #28861, I haven't done a full bisect to figure out when it broke.

@carolinan carolinan added [Block] Navigation Affects the Navigation Block [Type] Bug An existing feature does not function as intended labels Feb 27, 2021
@georgeh
Copy link
Contributor Author

georgeh commented Mar 1, 2021

Commenting out <ul { ...innerBlocksProps } /> in packages/block-library/src/navigation-link/edit.js fixes the crash. The full trace of the crash is

Uncaught Error: Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
    React 3
    onStoreChange index.js:159
    onChange index.js:175
    Redux 3
react-dom.development.js:23228:17
    React 3
    dispatchAction self-hosted:1277
    onStoreChange index.js:159
    onChange index.js:175
    Redux 3
    promiseMiddleware promise-middleware.js:20
    createResolversCacheMiddleware resolvers-cache-middleware.js:52
    createBoundAction Redux
    useNestedSettingsUpdate use-nested-settings-update.js:75
    React 7
    commitRootImpl self-hosted:1277
    React 5
    performSyncWorkOnRoot self-hosted:1220
    React 7
    dispatchAction self-hosted:1277
    onStoreChange index.js:159
    onChange index.js:175
    Redux 3
    promiseMiddleware promise-middleware.js:20
    createResolversCacheMiddleware resolvers-cache-middleware.js:52
    createBoundAction Redux
    startTypingInTextField index.js:233
    (Async: EventListener.handleEvent)
    ref2 index.js:237
    useRefEffect index.js:29
    useMergeRefs index.js:68
    forEach self-hosted:206
    useMergeRefs index.js:66
    useMergeRefs index.js:68
    forEach self-hosted:206
    useMergeRefs index.js:66
    React 6
    commitRootImpl self-hosted:1277
    React 5
    performSyncWorkOnRoot self-hosted:1220
    React 7
    dispatchAction self-hosted:1277
    onStoreChange index.js:159
    onChange index.js:175
    Redux 3
    promiseMiddleware promise-middleware.js:20
    createResolversCacheMiddleware resolvers-cache-middleware.js:52
    Redux 2
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:38
    any builtin.js:15
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:37
    (Async: promise callback)
    rungenControls Redux
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:38
    rungenControls Redux
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:38
    iterate create.js:51
    runtime create.js:73
    iterator builtin.js:90
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:38
    any builtin.js:15
    next create.js:47
    some self-hosted:165
    next create.js:46
    unhandledActionControl Redux
    next create.js:47
    some self-hosted:165
    next create.js:46
    yieldValue create.js:38
    any builtin.js:15
    next create.js:47
    some self-hosted:165
    next create.js:46
The above error occurred in the <UncontrolledInnerBlocks> component:
    in UncontrolledInnerBlocks (created by NavigationLinkEdit)
    in ul (created by NavigationLinkEdit)
    in li (created by NavigationLinkEdit)
    in NavigationLinkEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by Navigation)
    in ul (created by Navigation)
    in nav (created by Navigation)
    in Navigation (created by WithDispatch(Navigation))
    in WithDispatch(Navigation)
    in Unknown (created by WithSelect(WithDispatch(Navigation)))
    in WithSelect(WithDispatch(Navigation)) (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by BlockList)
    in div (created by BlockList)
    in BlockList (created by VisualEditor)
    in div (created by WritingFlow)
    in WritingFlow (created by VisualEditor)
    in div (created by VisualEditor)
    in div (created by VisualEditor)
    in VisualEditor (created by Layout)
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in ForwardRef(InterfaceSkeleton) (created by Layout)
    in Layout (created by Editor)
    in ErrorBoundary (created by Editor)
    in BlockEditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(BlockEditorProvider) (created by EditorProvider)
    in BlockContextProvider (created by EditorProvider)
    in EntityProvider (created by EditorProvider)
    in EntityProvider (created by EditorProvider)
    in EditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(EditorProvider) (created by Editor)
    in DropZoneContextProvider (created by Editor)
    in SlotFillProvider (created by SlotFillProvider)
    in SlotFillProvider (created by Editor)
    in StrictMode (created by Editor)
    in Editor

React will try to recreate this component tree from scratch using the error boundary you provided, BlockCrashBoundary. react_devtools_backend.js:2430:23

I'm going to keep trying to see if I can figure out a fix for this.

@Copons
Copy link
Contributor

Copons commented Mar 1, 2021

Hi @georgeh, I'm gonna piggyback on this issue if you don't mind! 🙂

A few days ago we noticed a similar issue on an alpha version of WordPress.com, logged here: Automattic/wp-calypso#50277.
The repro steps provided in that issue weren't triggering any problem on Core Gutenberg.
Although, today I've casually stumbled upon a few crashes with the Navigation block, that seem very similar to what you are describing.
Interestingly, the outcome is different if the test is done on the Post Editor or the Site Editor.

Post Editor

  1. Open the Post Editor.
  2. Insert a Navigation block.
  3. Select "Start empty".
    This is because "Add all pages" inserts a PageList block, whereas the error seems related to the NavigationLink block, used for single (external and internal) links.
  4. Add a link, external or internal it's the same.
  5. Once the link is done and displayed in the Navigation block, select it.
  6. Press the up or down arrow on the keyboard, as to navigate away.

The NavigationLink block crashes with roughly the same errors reported above:

Uncaught Error: Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
    at checkForNestedUpdates (react-dom.82e849f1.js:23228)
    at scheduleUpdateOnFiber (react-dom.82e849f1.js:21299)
    at dispatchAction (react-dom.82e849f1.js:15795)
    at onStoreChange (index.js:159)
    at onChange (index.js:175)
    at index.js:175
    at Object.dispatch (redux.js:221)
    at e (:1:40553)
    at index.js:24
    at promise-middleware.js:20
The above error occurred in the <UncontrolledInnerBlocks> component:
    in UncontrolledInnerBlocks (created by NavigationLinkEdit)
    in ul (created by NavigationLinkEdit)
    in li (created by NavigationLinkEdit)
    in NavigationLinkEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by Navigation)
    in ul (created by Navigation)
    in nav (created by Navigation)
    in Navigation (created by WithDispatch(Navigation))
    in WithDispatch(Navigation)
    in Unknown (created by WithSelect(WithDispatch(Navigation)))
    in WithSelect(WithDispatch(Navigation)) (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by ColumnEdit)
    in div (created by ColumnEdit)
    in ColumnEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by ColumnsEditContainer)
    in div (created by ColumnsEditContainer)
    in ColumnsEditContainer (created by WithDispatch(ColumnsEditContainer))
    in WithDispatch(ColumnsEditContainer) (created by ColumnsEdit)
    in ColumnsEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in div (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by ControlledInnerBlocks)
    in ControlledInnerBlocks (created by TemplatePartInnerBlocks)
    in div (created by TemplatePartInnerBlocks)
    in TemplatePartInnerBlocks (created by TemplatePartEdit)
    in header (created by TemplatePartEdit)
    in TemplatePartEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in div (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by BlockList)
    in div (created by BlockList)
    in BlockList (created by BlockEditor)
    in div (created by WritingFlow)
    in WritingFlow (created by BlockEditor)
    in div (created by DropContainer)
    in DropContainer (created by DropZoneProvider)
    in DropZoneContextProvider (created by DropZoneProvider)
    in DropZoneProvider (created by BlockEditor)
    in iframe (created by ForwardRef(Iframe))
    in ForwardRef(Iframe) (created by BlockEditor)
    in div (created by BlockEditor)
    in BlockEditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(BlockEditorProvider) (created by BlockEditor)
    in BlockEditor (created by Editor)
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in ForwardRef(InterfaceSkeleton) (created by Editor)
    in GlobalStylesProvider (created by Editor)
    in BlockContextProvider (created by Editor)
    in EntityProvider (created by Editor)
    in EntityProvider (created by Editor)
    in EntityProvider (created by Editor)
    in div (created by DropContainer)
    in DropContainer (created by DropZoneProvider)
    in DropZoneContextProvider (created by DropZoneProvider)
    in DropZoneProvider (created by Editor)
    in SlotFillProvider (created by SlotFillProvider)
    in SlotFillProvider (created by Editor)
    in Editor

Site Editor (with a demo template content)

  1. Install an FSE theme such as TT1 Blocks.
  2. Open the Site Editor.
  3. Select any of the demo links in the Navigation block.
  4. Press the up or down arrow on the keyboard, as to navigate away.

The NavigationLink block or sometimes even the entire editor crashes with roughly the same errors reported above:

Uncaught Error: Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
    at checkForNestedUpdates (react-dom.82e849f1.js:23228)
    at scheduleUpdateOnFiber (react-dom.82e849f1.js:21299)
    at Object.enqueueForceUpdate (react-dom.82e849f1.js:12813)
    at SlotComponent.Component.forceUpdate (react.af754d50.js:576)
    at SlotComponent.forceUpdate (slot.js:58)
    at fill.js:38
    at commitHookEffectListMount (react-dom.82e849f1.js:19866)
    at commitLifeCycles (react-dom.82e849f1.js:19922)
    at commitLayoutEffects (react-dom.82e849f1.js:22938)
    at HTMLUnknownElement.callCallback (react-dom.82e849f1.js:182)
The above error occurred in the <FillComponent> component:
    in FillComponent (created by Context.Consumer)
    in Fill (created by Fill)
    in Fill (created by RichTextToolbarButton)
    in RichTextToolbarButton (created by edit)
    in edit (created by FormatEdit)
    in FormatEdit (created by ForwardRef(RichText))
    in ForwardRef(RichText) (created by ForwardRef(RichTextWrapper))
    in ForwardRef(RichTextWrapper) (created by NavigationLinkEdit)
    in div (created by NavigationLinkEdit)
    in li (created by NavigationLinkEdit)
    in NavigationLinkEdit (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by UncontrolledInnerBlocks)
    in BlockContextProvider (created by UncontrolledInnerBlocks)
    in UncontrolledInnerBlocks (created by Navigation)
    in ul (created by Navigation)
    in nav (created by Navigation)
    in Navigation (created by WithDispatch(Navigation))
    in WithDispatch(Navigation)
    in Unknown (created by WithSelect(WithDispatch(Navigation)))
    in WithSelect(WithDispatch(Navigation)) (created by Edit)
    in Edit (created by WithToolbarControls(Edit))
    in WithToolbarControls(Edit) (created by WithInspectorControl(WithToolbarControls(Edit)))
    in WithInspectorControl(WithToolbarControls(Edit)) (created by WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))) (created by WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit)))))
    in WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))
    in Unknown (created by WithDispatch(Component))
    in WithDispatch(Component)
    in Unknown (created by WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))))
    in WithMultipleValidation(WithToolbarControls(WithInspectorControl(WithInspectorControl(WithToolbarControls(Edit))))) (created by WithFilters(Edit))
    in WithFilters(Edit) (created by BlockEdit)
    in BlockEdit (created by BlockListBlock)
    in BlockCrashBoundary (created by BlockListBlock)
    in BlockListBlock (created by (BlockListBlock))
    in (BlockListBlock) (created by ((BlockListBlock)))
    in ((BlockListBlock)) (created by WithFontSizeInlineStyles(((BlockListBlock))))
    in WithFontSizeInlineStyles(((BlockListBlock))) (created by WithFilters(BlockListBlock))
    in WithFilters(BlockListBlock) (created by IfCondition(WithFilters(BlockListBlock)))
    in IfCondition(WithFilters(BlockListBlock)) (created by WithDispatch(IfCondition(WithFilters(BlockListBlock))))
    in WithDispatch(IfCondition(WithFilters(BlockListBlock)))
    in Unknown (created by Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))))
    in Pure(WithSelect(WithDispatch(IfCondition(WithFilters(BlockListBlock))))) (created by Items)
    in Items (created by BlockListItems)
    in BlockListItems (created by BlockList)
    in div (created by BlockList)
    in BlockList (created by VisualEditor)
    in div (created by WritingFlow)
    in WritingFlow (created by VisualEditor)
    in div (created by VisualEditor)
    in div (created by VisualEditor)
    in VisualEditor (created by Layout)
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in ForwardRef(InterfaceSkeleton) (created by Layout)
    in Layout (created by Editor)
    in ErrorBoundary (created by Editor)
    in BlockEditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(BlockEditorProvider) (created by EditorProvider)
    in BlockContextProvider (created by EditorProvider)
    in EntityProvider (created by EditorProvider)
    in EntityProvider (created by EditorProvider)
    in EditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(EditorProvider) (created by Editor)
    in DropZoneContextProvider (created by Editor)
    in SlotFillProvider (created by SlotFillProvider)
    in SlotFillProvider (created by Editor)
    in StrictMode (created by Editor)
    in Editor

Another time the error occurred in another component:

The above error occurred in the < __experimentalBlockVariationTransforms> component:
    in __experimentalBlockVariationTransforms (created by BlockInspectorSingleBlock)
    in div (created by BlockInspectorSingleBlock)
    in BlockInspectorSingleBlock (created by BlockInspector)
    in BlockInspector
    in Unknown (created by WithSelect(BlockInspector))
    in WithSelect(BlockInspector) (created by BlockEditor)
    in Fill (created by Fill)
    in Fill (created by EditSiteSidebarInspectorFill)
    in EditSiteSidebarInspectorFill (created by BlockEditor)
    in BlockEditorProvider
    in Unknown (created by Context.Consumer)
    in WithRegistryProvider(BlockEditorProvider) (created by BlockEditor)
    in BlockEditor (created by Editor)
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in div (created by ForwardRef(InterfaceSkeleton))
    in ForwardRef(InterfaceSkeleton) (created by Editor)
    in GlobalStylesProvider (created by Editor)
    in BlockContextProvider (created by Editor)
    in EntityProvider (created by Editor)
    in EntityProvider (created by Editor)
    in EntityProvider (created by Editor)
    in div (created by DropContainer)
    in DropContainer (created by DropZoneProvider)
    in DropZoneContextProvider (created by DropZoneProvider)
    in DropZoneProvider (created by Editor)
    in SlotFillProvider (created by SlotFillProvider)
    in SlotFillProvider (created by Editor)
    in Editor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Navigation Affects the Navigation Block [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
5 participants