Error: Field moderation_state is unknown

Created on 8 August 2025, 4 days ago

Problem/Motivation

When upgrading from 2.0-beta2 to beta4 and above, a fatal error is thrown with the above error message. This is in the command line and on the site. Discussed in Drupal slack and there was a new workflow for events that requires content moderation without checking if it is configured.

This may only be an upgrade issue as beta4 and above configure the moderation state.

Steps to reproduce

Upgrade event platform to beta4 or above. In todays episode I was upgrading to 2.0.2 to get the security update to config_pages.

Proposed resolution

Update `event_platform_details/src/Plugin/Block/EventPlatformHeaderCtaBlock.php` line 135 to check if the entity has a moderation_state

Update `event_platform_details/src/Cache/Context/SessionsOpen.php` line 62 to check if entity has moderation_state.

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States markie Albuquerque, NM

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

Comments & Activities

Production build 0.71.5 2024