Closed (fixed)
Project:
Metatag
Version:
2.2.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
15 Aug 2026 at 12:01 UTC
Updated:
15 Sep 2026 at 19:40 UTC
Jump to comment: Most recent
There are some phpcs bugs in 2.2.x. Fix them and make phpcs required in .gitlab-ci.yml.
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
Comment #4
yusuf_khan commented@damienmckenna
Please review
Comment #5
damienmckennaI'd prefer to keep the autowired service and use another mechanism to add it, e.g. extending ServiceProviderBase to add the service if the Migrate module is installed.
I commented out the MigrateHooks class in metatag.services.yml and tried this:
With that change it then gives the following error:
That doesn't make sense to me?
Comment #6
csakiistvan@damienmckenna ❌ Does not fix the issue — MR !258 at
dbc2275bbreaks the container. Answering your question from #5 below.The
MigrateHooksservice is not registered bymetatag.services.ymlbut by core'sHookCollectorPass, so commenting the YAML entry out and adding a service provider both have no effect. Using#[Autowire(service: 'plugin.manager.migrate.destination')]in the constructor builds the container with Migrate installed and uninstalled alike — both were tried.Comment #8
damienmckennaI think #3620074: Move migration logic into submodule will take care of my concerns.
Comment #9
damienmckennaComment #12
damienmckennaI created a clean MR using the two original commits, let's see if it works this time.
Comment #14
damienmckennaCommitted. Thank you!