There is no purger supporting 'Array'

Created on 9 July 2024, 9 months ago

Problem/Motivation

I got this error when I ran "drush pqa everything -y"
In QueueCommands.php linke 200:
"There is no purger supporting 'Array' Please install one!"

Steps to reproduce

1. update purge from 3.5 to 3.6 in D10.2.7
2. drush updb && drush cr
3. drush pqa everything -y

Proposed resolution

The main issue is caused by setting "expression" argument as array then the argument as array instead of string passes to "queueAddParseExpressions" function again.

So, I proposed to add if condition for checking argument type at the top of function logic like below:
if(!is_string($input->getArguments()['expressions'])) {
return;
}

$raw = trim(implode(" ", $input->getArguments()['expressions']));

Remaining tasks

If 3.6 works in D10.3.x, please set core_version_requirement for Drupal compatibility.

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Active

Version

3.6

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States parkh

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

Comments & Activities

  • Issue created by @parkh
  • πŸ‡ΊπŸ‡ΈUnited States parkh
  • πŸ‡ΊπŸ‡ΈUnited States parkh
  • πŸ‡ΊπŸ‡ΈUnited States parkh
  • πŸ‡¦πŸ‡ΊAustralia silverham

    Attaching patch uses static variable instead, so format is not locked in. not sure why it added twice though.

  • Status changed to Needs review 9 months ago
  • πŸ‡¦πŸ‡ΊAustralia silverham
  • πŸ‡ΊπŸ‡ΈUnited States parkh
  • πŸ‡ΊπŸ‡ΈUnited States parkh

    @silverham, the patch works for me. thank you.

  • Status changed to Needs work 6 months ago
  • πŸ‡ΊπŸ‡ΈUnited States andyg5000 North Carolina, USA

    The init hook is getting registered twice by Drush because of a drush.services.yml and the auto-discovery service that Drush invokes. We should remove the command in drush.services.yml and let the auto-discovery handle registering the commands.

    I would like the module maintainers to review this before making an MR because there are several commands that are impacted by this.

  • πŸ‡ΊπŸ‡ΈUnited States andyg5000 North Carolina, USA

    Here's a temp patch I'm using for now until we can get the module maintainers eyes on this. I don't think we need to reference any of the drush.services.yml stuff and removing it fixes the duplicate hook registrations.

  • Status changed to RTBC 17 days ago
  • πŸ‡§πŸ‡ͺBelgium lisotton Brussels

    I'm also facing this issue and it took me hours to realize that the issue was the auto-discovery + the drush.services.yml.

    @andyg5000 your patch #9 is working fine, so why not moving this ticket to RTBC?
    Maybe we can speed up and catch more attention from the maintainers if you also open a MR in Gitlab.

Production build 0.71.5 2024