Errors With VBO and IEF

Created on 29 April 2021, over 3 years ago
Updated 11 July 2023, over 1 year ago

Problem/Motivation

There are two errors that keep happening on the ScheduledPublishWidget FieldWidget.

One happens when you have Scheduled Publish working on an Inline Entity Form:

The website encountered an unexpected error. Please try again later.
Error: Call to undefined method Drupal\entity_browser\Form\EntityBrowserForm::getEntity() in Drupal\scheduled_publish\Plugin\Field\FieldWidget\ScheduledPublishWidget->formElement() (line 37 of modules/contrib/scheduled_publish/src/Plugin/Field/FieldWidget/ScheduledPublishWidget.php).

And the other is happening with Views Bulk Operations:

The website encountered an unexpected error. Please try again later.
Error: Call to undefined method Drupal\views_bulk_operations\Form\ConfigureAction::getEntity() in Drupal\scheduled_publish\Plugin\Field\FieldWidget\ScheduledPublishWidget->formElement() (line 37 of modules/contrib/scheduled_publish/src/Plugin/Field/FieldWidget/ScheduledPublishWidget.php).

It's the same error.

Steps to reproduce

IEF:

  • Have an Inline Entity Form on a node that has a scheduled publish
  • Go to that form and try to save

VBO:

  • Have VBO with Views Bulk Edit installed
  • Create a view with it
  • Try to perform a Modify field values on a node that has a scheduled publish

Proposed resolution

Address the error.

Remaining tasks

I thought the patch in https://www.drupal.org/project/scheduled_publish/issues/3171296 🐛 Call to a member function getTypePlugin() on null in Drupal\scheduled_publish\Plugin\Field\FieldWidget\ScheduledPublishWidget->formElement() Needs work would fix it but it did not.

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Needs work

Version

3.9

Component

Code

Created by

🇺🇸United States niles38

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.

  • 🇮🇪Ireland lostcarpark

    I'd like to incorporate this fix into the module, but going forward I would like to see test coverage for bug fixes and new features where possible.

    I'd welcome any thoughts on what a test for this would look like.

Production build 0.71.5 2024