Closed
Description
Symfony version(s) affected
7.0
Description
When updating Symfony Demo to 7.0, I'm seeing this error:
An exception has been thrown during the rendering of a template:
"Callable "Symfony\Bundle\FrameworkBundle\Controller\TemplateController::templateAction()"
is not allowed as a controller.
Did you miss tagging it with "#[AsController]" or registering its type with
"Symfony\Component\HttpKernel\Controller\ControllerResolver::allowControllers()"?"
This error doesn't happen in 6.4.
How to reproduce
Just run the Symfony Demo with 7.0. Whenever Symfony finds a TemplateController::templateAction
it will show the error. For example:
Possible Solution
I don't know. But this only happens in Symfony 7.0, not 6.4.
Additional Context
No response