Panelizer migration to Layout Builder breaks if a revision references a non-existent custom block

Created on 17 May 2021, over 3 years ago
Updated 25 October 2023, about 1 year ago

Problem/Motivation

I have been attempting to migrate some Landing Pages on my dev/test servers from Panelizer to Layout Builder. However, it appears some of the previous revisions of some of these pages reference blocks that no longer exist. This appears to be breaking the migration, resulting in many of the landing pages without any content on them.

When I look at the PHP log, it will give an error such as the following:

"The "block_content:b443ae9f-c0af-45a3-a9a2-c7edb1e97904" plugin does not exist.

followed by a list of modules (and blocks) that are allowed. I've peeked into the database and found blocks in revisions that no longer exist (verified by going to those revisions and seeing an error). Removing these revisions does appear to allow the migration to progress (until it hits the next one).

This is my first time submitting a ticket, so if you would like more information, let me know.

Edit:
Additional info -

I'm using Panelizer 8.x-5.0-beta3, Drupal 8.9.15 (on dev) and 8.9.13 (on test). Layout Builder, Layout Discovery, and Core Context are all enabled.

Edit #2:

So while I think this is still an issue b/c one shouldn't need to muck through revisions to delete them, one of my issues is that on one of my landing pages, *every revision* including the published one allegedly has an unpublished block on it. But I can't find it when I edit the page to get rid of it. I *think* the issue with that is I am using Flexible Layout β†’ and I'm guessing maybe I had inserted a row, then put a block in, then maybe deleted the row without deleting the block, and now I have this block just floating as part of the page in the database but not actually connected to any part of the page. In any case, I can see all the other blocks assigned to particular columns on the page, but this one has no column set.

I thought I'd add that as some additional information.

Steps to reproduce

Attempt to migrate a content type set up to use Panelizer to Layout Builder, but have revisions in some of the nodes that use custom blocks that no longer exist.

Proposed resolution

TBD

Remaining tasks

TBD

User interface changes

TBD

API changes

TBD

Data model changes

TBD

πŸ› Bug report
Status

Needs review

Component

Layout Builder migration

Created by

πŸ‡ΊπŸ‡ΈUnited States josh.chambers West Virginia

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024