Problem/Motivation

Follow up from #2982949: Introduce CallableResolver to help standardise the DX and error handling for callbacks across various subsystems We should use CallableResolver for \Drupal\Core\Menu\MenuLinkTree::transform (and \Drupal\toolbar\Menu\ToolbarMenuLinkTree which subclasses it).

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Issue fork drupal-3363421

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

kim.pepper created an issue. See original summary.

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

vbouchet’s picture

kim.pepper’s picture

Status: Needs work » Needs review

Fix service args

smustgrave’s picture

Status: Needs review » Needs work
Issue tags: +Needs change record

Believe this will need it's own change record. The one being referenced is referring to a different class.

vbouchet’s picture

Thanks for pointing @smustgrave. I created the following change record (https://www.drupal.org/node/3395294) and updated the deprecation message in the code. I assume that now the deprecation is added in 11.0.0, it will be removed in 11.1.0.

vbouchet’s picture

Status: Needs work » Needs review
smustgrave’s picture

It will be added in 10.2.0 and removed in 11.0.0

The 11.x branch is just the development branch until "main" can be used

vbouchet’s picture

Issue tags: -Needs change record

Thanks @smustgrave. I updated the message to 'Calling ' . __METHOD__ . '() with an argument of ControllerResolverInterface is deprecated in drupal:10.2.0 and is removed in drupal:11.0.0. Use \Drupal\Core\Utility\CallableResolver instead. See https://www.drupal.org/node/3395294'

smustgrave’s picture

Status: Needs review » Reviewed & tested by the community

Thanks! Pipeline is green so don't see a new to wait for drupalci

smustgrave’s picture

And just to provide more context in #9. 11.x is the current "development" or "main" branch, currently can't use named branches. But all D10 releases will be tagged off 11.x, for example when 10.2 releases soon it will be made off 11.x. This helps so that issues don't continuously have to be moved between branches like 10.0, 10.1.x, 10.2.x, etc.

longwave’s picture

Version: 11.x-dev » 10.2.x-dev
Status: Reviewed & tested by the community » Fixed

Committed and pushed 0beb71bd73 to 11.x and 0b51914925 to 10.2.x. Thanks!

Also published the change record.

  • longwave committed 0b519149 on 10.2.x
    Issue #3363421 by vbouchet, kim.pepper, smustgrave: Use CallableResolver...

  • longwave committed 0beb71bd on 11.x
    Issue #3363421 by vbouchet, kim.pepper, smustgrave: Use CallableResolver...

  • quietone committed 41d654b6 on 10.2.x
    Revert "Issue #3363421 by vbouchet, kim.pepper, smustgrave: Use...

  • quietone committed b4d653d7 on 10.2.x
    Revert "Revert "Issue #3363421 by vbouchet, kim.pepper, smustgrave: Use...
quietone’s picture

I accidentally reverted this issue. I meant to revert #3363420: Use CallableResolver for \Drupal\Core\Render\Renderer::doCallback()

Sorry for the noise.

Status: Fixed » Closed (fixed)

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