我需要使用Symfony fork来测试BugFix。我的composer.json
是:
{
...
"repositories": {
"symfony": {
"type": "git",
"url": "https://github.com/nicolas-grekas/symfony.git"
}
},
"require": {
...
"symfony-bundles/redis-bundle": "2.*",
"symfony/console": "4.*",
"symfony/flex": "1.*",
"symfony/framework-bundle": "4.*",
"symfony/lts": "^4@dev",
"symfony/monolog-bundle": "3.*",
"symfony/proxy-manager-bridge": "4.*",
"symfony/yaml": "4.*"
},
"require-dev": {
...
},
...
}
(完整代码在这里:github)
运行命令,例如
-
composer require symfony/symfony "dev-cache-fix"
-
composer require symfony/symfony "dev-cache-fix as 4.2.1-dev"
错误:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for __root__ dev-fork -> satisfiable by __root__[dev-fork].
- symfony/symfony dev-cache-fix conflicts with __root__[dev-fork].
- Installation request for symfony/symfony dev-cache-fix as 4.2.1-dev -> satisfiable by symfony/symfony[dev-cache-fix].
如何解决此问题?
我需要删除所有Symfony组件(Monolog-Bundle除外,因为它不在FullStack Framework之外),Clean Composer选项conflict
和replace
。之后,我需要将behat/mink
的版本更改为dev-master
,因为最新的稳定范围1.7.1锁定symfony/assets
组件转换为 3.x
版本(essue github/minkphp)。最后一步是启用config/packages/framework.yaml
中的所有使用组件。
framework:
validation:
enabled: true
enable_annotations: true
assets:
enabled: true
serializer:
enabled: true
enable_annotations: true
annotations:
enabled: true
property_info:
enabled: true