Call to a member function getEnergy() on null

Created on 21 March 2024, 8 months ago
Updated 3 September 2024, 3 months ago

Things break when referenced entities cant be loaded. This stops the execution of cron on the site completely.

Message: Call to a member function getEnergy() on null in Drupal\radioactivity\RadioactivityProcessor->queueProcessIncidents() (line 467 of /var/www/html/htdocs/modules/contrib/radioactivity/src/RadioactivityProcessor.

πŸ› Bug report
Status

Active

Version

4.0

Component

Code

Created by

πŸ‡³πŸ‡±Netherlands EsfoNL

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

Comments & Activities

  • Issue created by @EsfoNL
  • πŸ‡ΊπŸ‡ΈUnited States John Franklin

    Can this patch be updated to create a new radioactivity entity if there is a field reference but no entity? The module does not create entities when we add a new radioactivity field to a content type/taxonomy/etc. with exiting content.

    It seems sensible to (offer an option to) create entities on demand. The downside of doing so is we have to call save() on the entity during processing, which may trigger a lot of other activity, including adding the node to a workflow queue.

    Option B is to update the field data directly without calling save() on the parent entity, which bypasses revision histories and may have its own issues.

Production build 0.71.5 2024