2
votes

Getting a bunch of these warnings now on several Composer commands.

composer dump-autoload

TYPO3 Extension Package "bk2k/bootstrap-package", does not define extension key in composer.json.
Specifying the extension key will be mandatory in future versions of TYPO3 (see: https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ExtensionArchitecture/ComposerJson/Index.html#extra)
TYPO3 Extension Package "typo3/cms-introduction", does not define extension key in composer.json.
Specifying the extension key will be mandatory in future versions of TYPO3 (see: https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ExtensionArchitecture/ComposerJson/Index.html#extra)

The obvious fix is to define the extension key in the "extra" section of every extension as explained in https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ExtensionArchitecture/ComposerJson/Index.html#extra

I can do (already did) that for my own extensions.

I can also create PR for other extensions (which I already started doing).

But for other third party extensions I am not sure if these will still accept changes for the latest version which supports TYPO3 9 (some have latest versions which support 10 and above).

The warning is starting to get annoying because it appears multiple times.


Update: some links:

2
The "multiple times" problem will be resolved with the next release of typo3/cms-composer-installersJonas Eberle
@Jonas Yes, I just saw that too. Good job. That already helps a lot. I have also been going through the closed PRs which already answers some of my questions: github.com/TYPO3/CmsComposerInstallers/…Sybille Peters

2 Answers

3
votes

Behavior was introduced in typo3/cms-composer-installers v3.1.0.

There is some ongoing improvements in that area, so this question might be outdated soon. See:

https://github.com/TYPO3/CmsComposerInstallers/issues/114

Downgrading to v3.0.1 might be the quick solution if you can't wait:

composer require typo3/cms-composer-installers '~3.0.1'

One additional hint: If you have local extensions being loaded via composer and you add the extension-key as documented and are not seeing the warning gone for this extension, the problem might come from composer's caching. Try removing it:

test -d "$(composer config vendor-dir)" && rm -rf $(composer config vendor-dir)
composer clear-cache
1
votes

You can use composer req typo3/cms-composer-installers:3.0.1 to load the older version without the check.