[英]Argument 1 passed to Sonata\PageBundle\Entity\BlockInteractor::__construct() must be an instance of Symfony\Bridge\Doctrine\RegistryInterface
After composer update i get new errors作曲家更新后,我收到新错误
Argument 1 passed to Sonata\PageBundle\Entity\BlockInteractor::__construct() must be an instance of Symfony\Bridge\Doctrine\RegistryInterface, instance of Doctrine\Bundle\DoctrineBundle\Registry given,
symfony config symfony 配置
"sonata-project/admin-bundle": "^3.48",
"sonata-project/doctrine-orm-admin-bundle": "^3.9",
"sonata-project/page-bundle": "^3.11",
"sonata-project/translation-bundle": "^2.4",
"sonata-project/user-bundle": "^4.3",
"symfony/console": "4.3.*",
"symfony/dotenv": "4.3.*",
"symfony/flex": "^1.1",
"symfony/framework-bundle": "4.3.*",
not sure but try extends AsbtractController instead of Controller and use dependancy injection, i had similar problem with bundle for pagination不确定,但尝试扩展 AsbtractController 而不是 Controller 并使用依赖注入,我在用于分页的包中遇到了类似的问题
//the use for my example
use Knp\Component\Pager\PaginatorInterface;
public function recap(Request $request, PaginatorInterface $paginator)
, maybe it's that ,也许是这样
That issue shows when auto update doctrine-bundle (to "version": "2.0.2" )该问题显示何时自动更新学说捆绑(到 "version": "2.0.2" )
"doctrine/doctrine-bundle": "1.12.2",
This work.这项工作。
Here are more pieces of information https://github.com/symfony/symfony/issues/29810这里有更多信息https://github.com/symfony/symfony/issues/29810
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.