我想升级我们项目背后的CakePHP框架。当前,我们正在使用3.8.10版本。我完成了所有步骤以完成此处描述的过程:https://book.cakephp.org/4/en/appendices/4-0-upgrade-guide.html(我的代码中没有错误,警告或注意事项)
所有步骤都很好,但是最后一步。
我运行以下命令后:
php composer.phar require --update-with-dependencies “cakephp/cakephp:4.0.*”
我收到以下错误消息:
Problem 1
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.x-dev] but these conflict with your requirements or minimum-stability.
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.x-dev] but these conflict with your requirements or minimum-stability.
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.x-dev] but these conflict with your requirements or minimum-stability.
- Installation request for cakephp/bake (locked at 1.12.0, required as ^1.9.0) -> satisfiable by cakephp/bake[1.12.0].
您能帮我找出问题吗?我在做什么错?
Cakephp github repository上已经列出了类似的问题
要解决此问题,您需要使用"cakephp/bake": "4.x-dev"
OR
暂时,您还需要在composer.json
中添加以下设置,直到migrations
和twig-view
插件获得兼容CakePHP 4
的新稳定版本:
"minimum-stability": "dev",
"prefer-stable": true
您可以检查以下链接
https://github.com/cakephp/cakephp/issues/13114
https://github.com/cakephp/cakephp/issues/14043
https://github.com/cakephp/app/blob/4.0.0-alpha1/composer.json