[BUGFIX] Fix PackageManager event binding
PackageManager can not have DI tags assigned as it is a early container instance (injected from core Bootstrap). That caused the 'packagesMayHaveChanged' event to never be executed. We rather need to hookup the event listener using a service provider that extends the ListenerProvider. (That's pretty much the same, what the DI tags do in the background as well.) Notes: 1) To avoid similar future mistakes we also remove the unneeded `autoconfigure: false` from Configuration.yaml 2) This restriction (no DI tag configuration) does only apply to early instance services, which is a static list of core TYPO3 services. 3) We additionally drop the currently unused event callback PackageManager::beforeInstallationEventListener. It was not fully migrated to a PSR-14 event callback in #90249, which revealed that it is actually unneeded. The signal callback was introduced with #52766 in EXT:extensionmanager/ext_localconf.php, but became obsolete with later fixes: #71071 and #71455 ExtensionManagementService now calls (through Install/ListUtility) directly into packageManager instead of (mis-)using a signal/event. Resolves: #90955 Related: #90249 Releases: master Change-Id: I8943e6149743d527c9e1157e425eed3afa98b0d4 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/64156 Tested-by:TYPO3com <noreply@typo3.com> Tested-by:
Simon Gilli <typo3@gilbertsoft.org> Tested-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Simon Gilli <typo3@gilbertsoft.org> Reviewed-by:
Helmut Hummel <typo3@helhum.io> Reviewed-by:
Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by:
Benni Mack <benni@typo3.org>
Showing
- typo3/sysext/core/Classes/Package/PackageManager.php 0 additions, 8 deletionstypo3/sysext/core/Classes/Package/PackageManager.php
- typo3/sysext/core/Classes/ServiceProvider.php 13 additions, 0 deletionstypo3/sysext/core/Classes/ServiceProvider.php
- typo3/sysext/core/Configuration/Services.yaml 0 additions, 8 deletionstypo3/sysext/core/Configuration/Services.yaml
Please register or sign in to comment