/admin/structure/views not loading

Created on 11 January 2022, about 3 years ago
Updated 13 October 2023, over 1 year ago

Problem/Motivation

Not sure how my system got into this state, but I can't view the /admin/structure/views page. Instead, I get a WSOD with the error:

Drupal\Core\Entity\EntityMalformedException: The "view" entity cannot have a URI as it does not have an ID in Drupal\Core\Entity\EntityBase->toUrl() (line 161 of /var/www/html/gunpost/gpd8/web/core/lib/Drupal/Core/Entity/EntityBase.php).

I did some debugging and found from drush views:list I had an empty machine name and Name for a view that was enabled.

For me, the view was views.view.purchased_items_report

From the help of https://drupal.stackexchange.com/questions/273701/how-to-fix-view-with-n..., I then ran drush config:delete views.view.purchased_items_report and I finally load the /admin/structure/views page again.

Not sure if this is a bug directly related to the commerce_reports module, but the yml file is related.

Steps to reproduce

  • Go to /admin/structure/views to get WSOD
  • Run drush views:list
  • compare list with views.view.*.yml output from drush cex
  • Find the yml file that is missing from the list
  • Run drush config:delete views.view.purchased_items_report (or whatever the correct one is)
  • Go to /admin/structure/views to load the page properly

Proposed resolution

TBD

Remaining tasks

TBD

User interface changes

None

API changes

None

Data model changes

TBD

🐛 Bug report
Status

Closed: outdated

Version

1.0

Component

Code

Created by

🇨🇦Canada sagesolutions

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