Problem/Motivation

The following errors are from drupal 10 upgrade:

  1. Streamline field widget hooks
  2. Access checking must be explicitly specified on content entity queries

Steps to reproduce

Any updates attempt causes this.

Proposed resolution

Insert the second line here to comply with Drupal 10 requirement:

  $result = $query->condition($entity_info->getKey('bundle'), $field_config->getTargetBundle())
    ->accessCheck(FALSE)
    ->condition("{$field_config->getName()}.target_id", '', '<>')
    ->addTag('DANGEROUS_ACCESS_CHECK_OPT_OUT')
    ->execute();

Update the hook filefield_paths_field_widget_form_alter to filefield_paths_field_widget_single_element_form_alter

Remaining tasks

  1. Open MR
  2. Test
  3. Review
  4. Commit
CommentFileSizeAuthor
#6 13.patch2.05 KBmurilohp
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:

Comments

AndersTwo created an issue. See original summary.

pmichelazzo made their first commit to this issue’s fork.

murilohp’s picture

Issue summary: View changes
Status: Patch (to be ported) » Needs review

Thanks @AndersTwo to open this issue, I'm also having issues with the drupal 10 upgrade, I'll update the description with the error that I found and I'll update the MR with the fix. I'm also moving this to NR.

murilohp’s picture

Issue summary: View changes
murilohp’s picture

StatusFileSize
new2.05 KB

Just uploading a static patch because we cannot pin the MR in a commit to use

voleger made their first commit to this issue’s fork.

  • voleger committed f540e488 on 8.x-1.x authored by pmichelazzo
    Issue #3360236 by murilohp: Retroactive update crashes on Drupal 10 (fix...
voleger’s picture

Status: Needs review » Fixed

Fixed, thanks

Status: Fixed » Closed (fixed)

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