Problem/Motivation

Fatal error: Class Drupal\migrate_sandbox\Plugin\migrate\destination\MigrateSandboxEntityContentBase contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (Drupal\migrate\Plugin\migrate\destination\Entity::updateEntity) in /opt/drupal/web/modules/contrib/migrate_sandbox/src/Plugin/migrate/destination/MigrateSandboxEntityContentBase.php on line 13

Steps to reproduce

Select “Sandbox content entity” as a destination.

Proposed resolution

Add an empty updateEntity method.

Remaining tasks

Review and apply patch.

User interface changes

None.

API changes

None.

Data model changes

None.

CommentFileSizeAuthor
#7 gogowitsch-3421443.patch1.01 KBGogowitsch
gogowitsch.patch854 bytesGogowitsch
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Gogowitsch created an issue. See original summary.

danflanagan8’s picture

Version: 1.1.4 » 1.1.x-dev
Status: Needs review » Needs work
Related issues: +#3318888: Fix migrate destination entity PHPStan L0 issues

Whoa! How did this happen?!?

I checked the git history on Drupal\migrate\Plugin\migrate\destination\Entity.php and found this issue: #3318888: Fix migrate destination entity PHPStan L0 issues

Looks like that was committed to 11.x. I think the module should still work with D10.x. Otherwise I would reclassify this as critical.

Thatnks for the patch, @Gogowitsch. It looks like the right fix. We need to add that good old inherit to the docblock of the new method. Back to NW for that.

chetan 11 made their first commit to this issue’s fork.

chetan 11’s picture

Status: Needs work » Needs review

Please check the above MR.

danflanagan8’s picture

Status: Needs review » Needs work
Gogowitsch’s picture

Status: Needs work » Needs review
FileSize
1.01 KB

New patch ahead! I could not push to the fork in the MR, with Git telling me “You are not allowed to push code to this project.”

I have moved the empty function to the base class MigrateSandboxEntity and fixed the phpcs errors.

danflanagan8’s picture

Status: Needs review » Reviewed & tested by the community

Patch looks great. Thank you, @Gogowitsch!

danflanagan8’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.