Delete job item when corresponding entity is being deleted

Created on 7 September 2018, almost 6 years ago
Updated 24 November 2023, 7 months ago

Issue/motivation

It's possible to get into the situation when we have "ghost" job items which don't point to any entity. For example, you've requested a translation for a node but then deleted it. This might cause issues in providers which expect an existing entity in a job item.

Proposed solution

If the translatable entity is being deleted then corresponding job item should be deleted as well. If this is the last job item in the job then delete the job as well. Are there any limitations on the way of doing this?

✨ Feature request
Status

Needs review

Version

1.0

Component

Core

Created by

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.

  • πŸ‡ͺπŸ‡ΈSpain google01

    Unfortunately this patch is adding code without explicit accessCheck(TRUE/FALSE) to content entity queries.

    For example in the function "tmgmt_entity_delete" in the code file "tmgmt.module". This case is really worrying because it causes errors in the removal of any content, leaving Drupal 10 websites completely inoperative.

  • First commit to issue fork.
  • Open in Jenkins β†’ Open on Drupal.org β†’
    Core: 9.5.x + Environment: PHP 7.3 & MySQL 8
    last update 9 months ago
    119 pass
  • πŸ‡§πŸ‡ͺBelgium colorfield Brussels

    Added accessCheck() to the MR as it is a blocker when deleting any kind of entity, including configuration, so also causes deployment issues.

    We might still decide whether or not we want this behaviour to become the default one (see #16).

  • πŸ‡§πŸ‡ΎBelarus dewalt

    Just adding diff from the MR to use with composer. The diff applies for 1.15 modules version, but has conflicts with the latest dev version.

Production build 0.69.0 2024