Problem/Motivation

Type of Drupal\checklistapi\Commands\ChecklistapiCommands::$logger must be ?Psr\Log\LoggerInterface (as in class Drush\Commands\DrushCommands)

Steps to reproduce

  • Install the module in D10 instance
  • Run drush
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

Lal_ created an issue. See original summary.

Lal_’s picture

Status: Active » Needs review
nkoporec’s picture

Status: Needs review » Reviewed & tested by the community

The issue is fixed, setting as RTBC.

jcnventura’s picture

Status: Reviewed & tested by the community » Needs work

Yes, this fixes it.. But not correctly. Better drop the logger attribute completely and use $this->logger() instead, like Drush itself does.

jcnventura’s picture

Status: Needs work » Needs review
jcnventura’s picture

See #3278542: Update $logger definition to be compatible with Drupal 10 where @nkoporec did a 2nd commit very similar to my 2nd commit here.

nkoporec’s picture

Status: Needs review » Reviewed & tested by the community

Looks good to me, setting as RTBC.

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

  • TravisCarden committed 4b02386 on 2.1.x authored by Lal_
    Issue #3310067 by Lal_, jcnventura, TravisCarden, nkoporec: Use \Drush\...
TravisCarden’s picture

Title: D10 compatibility Type of Drupal\checklistapi\Commands\ChecklistapiCommands::$logger must be ?Psr\Log\LoggerInterface (as in class Drush\Commands\DrushCommands) » Use \Drush\Commands\DrushCommands::logger() in ChecklistapiCommands
Category: Bug report » Task
Status: Reviewed & tested by the community » Fixed

Merged. Thanks, everyone!

Status: Fixed » Closed (fixed)

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