500 error on Manage Layout page

Created on 4 February 2025, about 2 months ago

Problem/Motivation

Symfony\Component\Routing\Exception\InvalidParameterException: Parameter "entity_id" for route "frontend_editing.update_content" must match "[^/]++" ("" given) to generate a corresponding URL. in Drupal\Core\Routing\UrlGenerator->doGenerate() (line 209 of core/lib/Drupal/Core/Routing/UrlGenerator.php).

Steps to Reproduce

  1. Enable the Layout Builder module.
  2. Go to /admin/structure/types/manage/[BUNDLE]/display.
  3. Enable the Use Layout Builder checkbox.
  4. Save the form.
  5. Click on the Manage layout button.
  6. On the /admin/structure/types/manage/[BUNDLE]/display/default/layout page, a 500 error occurs.

Proposed Resolution

The issue can be resolved by fixing the frontend_editing_preprocess_block hook to prevent triggering errors for "new" entities when accessing the Manage display layout page.

🐛 Bug report
Status

Active

Version

1.8

Component

Code

Created by

🇵🇱Poland damian.skiba

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024