500 Error When Editing Code in Custom Code Component under Article Template

Created on 23 September 2025, 11 days ago
Updated 1 October 2025, 2 days ago

Overview

Steps to Reproduce

  1. Add a new template under an Article content type.
  2. Click on the created template to open it.
  3. Go to the Library, and add any Custom Code component to the template by clicking on the component.
  4. On the Canvas, double click on the added component and choose Edit Code.
  5. In the code editor header, click the "< Back" button.
  6. A 500 error occurs on the page.

Error Details

  • API Request: https://canvas-dev.ddev.site/canvas/api/v0/layout/node/1
  • Error message:
    {
        "message": "For now Canvas only works if the entity is a canvas_page! Other entity types and bundles must use content templates for now, see https://drupal.org/i/3498525",
        "file": "/var/www/html/web/modules/contrib/canvas/src/Storage/ComponentTreeLoader.php",
        "line": 60
    }
        
  • Page URL:
    https://canvas-dev.ddev.site/canvas/template/node/article/full/1/component/b4aa7a14-eb8d-4ce2-8616-4f4cfd67b78c

Proposed resolution

User interface changes

πŸ› Bug report
Status

Active

Version

1.0

Component

… to be triaged

Created by

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

Merge Requests

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