TYPO3 Exception 1476107941

[TYPO3 11.3] - [2021.08.13]

TYPO3 cannot configure Dependency Injection for the plugin controller.

Dependeny Injection may not be properly configured. Make sure that either the affected class or all classes (_defaults) have autoconfigure: true defined.

Bare minimum example:

Configuration/Services.yaml
services:
  _defaults:
    # ...
    autoconfigure: true
    # ...

# ...
Copied!

See Configuration in TYPO3 Explained.

[TYPO3 LTS 10] - [2021.05.05]

Unable to call the controller configured in a plugin.

TYPO3 creates the wrong class object for the controller due to using only the controller name (and not the fully qualified class name) in configurePlugin or registerModule.

Incorrect example:

ext_localconf.php
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
    'Examples', // $extensionName
    'HtmlParser', // plugin name
    // this is deprecated!
    ['ControllerName' => 'actionName'],
    // this is deprecated!
    ['ControllerName' => 'actionName']
);
Copied!

Use fully qualified class names as array keys in arguments $controllerActions and $nonCacheableControllerActions in configurePlugin or registerModule.

More details are in the changelog Deprecation: #87550 - Use controller classes when registering plugins/modules:

Correct example:

ext_localconf.php
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
    'Examples', // $extensionName
    'HtmlParser', // plugin name
    // controller class name => action name
    [\T3docs\Examples\Controller\HtmlParserController::class => 'search',],
    [\T3docs\Examples\Controller\HtmlParserController::class => 'search',]
);
Copied!