由于冲突,安装Laravel的代客时安装失败

时间:2017-12-14 05:31:32

标签: laravel composer-php laravel-5.4 laravel-valet symfony4

我在使用Laravel的Valet时遇到了一些问题,所以我尝试卸载并重新安装。重新安装后,当我输入命令composer global require laravel/valet时,我得到了这个非常冗长的错误

Your requirements could not be resolved to an installable set of packages.

Problem 1
- Conclusion: don't install symfony/process v3.4.1
- Conclusion: don't install laravel/valet v2.0.6
- Conclusion: don't install laravel/valet v2.0.5
- Conclusion: don't install laravel/valet v2.0.4
- Conclusion: don't install laravel/valet v2.0.3
- Conclusion: don't install laravel/valet v2.0.1
- Conclusion: don't install symfony/process v3.4.0
- Conclusion: remove symfony/console v4.0.1
- Conclusion: don't install symfony/console v4.0.1
- symfony/process v2.7.0 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.1 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.10 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.11 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.12 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.13 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.14 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.15 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.16 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.17 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.18 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.19 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.2 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.20 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.21 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.22 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.23 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.24 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.25 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.26 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.27 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.28 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.29 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.3 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.30 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.31 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.32 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.33 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.34 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.35 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.36 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.37 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.38 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.39 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.4 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.5 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.6 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.7 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.8 conflicts with symfony/console[v4.0.1].
- symfony/process v2.7.9 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.0 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.1 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.10 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.11 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.12 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.13 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.14 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.15 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.16 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.17 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.18 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.19 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.2 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.20 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.21 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.22 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.23 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.24 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.25 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.26 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.27 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.28 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.29 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.3 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.30 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.31 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.32 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.4 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.5 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.6 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.7 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.8 conflicts with symfony/console[v4.0.1].
- symfony/process v2.8.9 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.0 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.1 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.2 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.3 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.4 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.5 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.6 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.7 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.8 conflicts with symfony/console[v4.0.1].
- symfony/process v3.0.9 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.0 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.1 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.10 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.2 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.3 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.4 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.5 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.6 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.7 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.8 conflicts with symfony/console[v4.0.1].
- symfony/process v3.1.9 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.0 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.1 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.10 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.11 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.12 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.13 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.14 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.2 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.3 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.4 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.5 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.6 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.7 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.8 conflicts with symfony/console[v4.0.1].
- symfony/process v3.2.9 conflicts with symfony/console[v4.0.1].
- Conclusion: remove symfony/process v4.0.1|install symfony/process v2.7.0|install symfony/process v2.7.1|install symfony/process v2.7.10|install symfony/process v2.7.11|install symfony/process v2.7.12|install symfony/process v2.7.13|install symfony/process v2.7.14|install symfony/process v2.7.15|install symfony/process v2.7.16|install symfony/process v2.7.17|install symfony/process v2.7.18|install symfony/process v2.7.19|install symfony/process v2.7.2|install symfony/process v2.7.20|install symfony/process v2.7.21|install symfony/process v2.7.22|install symfony/process v2.7.23|install symfony/process v2.7.24|install symfony/process v2.7.25|install symfony/process v2.7.26|install symfony/process v2.7.27|install symfony/process v2.7.28|install symfony/process v2.7.29|install symfony/process v2.7.3|install symfony/process v2.7.30|install symfony/process v2.7.31|install symfony/process v2.7.32|install symfony/process v2.7.33|install symfony/process v2.7.34|install symfony/process v2.7.35|install symfony/process v2.7.36|install symfony/process v2.7.37|install symfony/process v2.7.38|install symfony/process v2.7.39|install symfony/process v2.7.4|install symfony/process v2.7.5|install symfony/process v2.7.6|install symfony/process v2.7.7|install symfony/process v2.7.8|install symfony/process v2.7.9|install symfony/process v2.8.0|install symfony/process v2.8.1|install symfony/process v2.8.10|install symfony/process v2.8.11|install symfony/process v2.8.12|install symfony/process v2.8.13|install symfony/process v2.8.14|install symfony/process v2.8.15|install symfony/process v2.8.16|install symfony/process v2.8.17|install symfony/process v2.8.18|install symfony/process v2.8.19|install symfony/process v2.8.2|install symfony/process v2.8.20|install symfony/process v2.8.21|install symfony/process v2.8.22|install symfony/process v2.8.23|install symfony/process v2.8.24|install symfony/process v2.8.25|install symfony/process v2.8.26|install symfony/process v2.8.27|install symfony/process v2.8.28|install symfony/process v2.8.29|install symfony/process v2.8.3|install symfony/process v2.8.30|install symfony/process v2.8.31|install symfony/process v2.8.32|install symfony/process v2.8.4|install symfony/process v2.8.5|install symfony/process v2.8.6|install symfony/process v2.8.7|install symfony/process v2.8.8|install symfony/process v2.8.9|install symfony/process v3.0.0|install symfony/process v3.0.1|install symfony/process v3.0.2|install symfony/process v3.0.3|install symfony/process v3.0.4|install symfony/process v3.0.5|install symfony/process v3.0.6|install symfony/process v3.0.7|install symfony/process v3.0.8|install symfony/process v3.0.9|install symfony/process v3.1.0|install symfony/process v3.1.1|install symfony/process v3.1.10|install symfony/process v3.1.2|install symfony/process v3.1.3|install symfony/process v3.1.4|install symfony/process v3.1.5|install symfony/process v3.1.6|install symfony/process v3.1.7|install symfony/process v3.1.8|install symfony/process v3.1.9|install symfony/process v3.2.0|install symfony/process v3.2.1|install symfony/process v3.2.10|install symfony/process v3.2.11|install symfony/process v3.2.12|install symfony/process v3.2.13|install symfony/process v3.2.14|install symfony/process v3.2.2|install symfony/process v3.2.3|install symfony/process v3.2.4|install symfony/process v3.2.5|install symfony/process v3.2.6|install symfony/process v3.2.7|install symfony/process v3.2.8|install symfony/process v3.2.9
- Conclusion: don't install symfony/process v3.3.14|keep symfony/process v4.0.1
- Installation request for symfony/console (locked at v4.0.1, required as ^4.0) -> satisfiable by symfony/console[v4.0.1].
- Installation request for laravel/valet ^2.0 -> satisfiable by laravel/valet[v2.0.0, v2.0.1, v2.0.3, v2.0.4, v2.0.5, v2.0.6].
- Conclusion: don't install symfony/process v4.0.1|install symfony/process v2.7.0|install symfony/process v2.7.1|install symfony/process v2.7.10|install symfony/process v2.7.11|install symfony/process v2.7.12|install symfony/process v2.7.13|install symfony/process v2.7.14|install symfony/process v2.7.15|install symfony/process v2.7.16|install symfony/process v2.7.17|install symfony/process v2.7.18|install symfony/process v2.7.19|install symfony/process v2.7.2|install symfony/process v2.7.20|install symfony/process v2.7.21|install symfony/process v2.7.22|install symfony/process v2.7.23|install symfony/process v2.7.24|install symfony/process v2.7.25|install symfony/process v2.7.26|install symfony/process v2.7.27|install symfony/process v2.7.28|install symfony/process v2.7.29|install symfony/process v2.7.3|install symfony/process v2.7.30|install symfony/process v2.7.31|install symfony/process v2.7.32|install symfony/process v2.7.33|install symfony/process v2.7.34|install symfony/process v2.7.35|install symfony/process v2.7.36|install symfony/process v2.7.37|install symfony/process v2.7.38|install symfony/process v2.7.39|install symfony/process v2.7.4|install symfony/process v2.7.5|install symfony/process v2.7.6|install symfony/process v2.7.7|install symfony/process v2.7.8|install symfony/process v2.7.9|install symfony/process v2.8.0|install symfony/process v2.8.1|install symfony/process v2.8.10|install symfony/process v2.8.11|install symfony/process v2.8.12|install symfony/process v2.8.13|install symfony/process v2.8.14|install symfony/process v2.8.15|install symfony/process v2.8.16|install symfony/process v2.8.17|install symfony/process v2.8.18|install symfony/process v2.8.19|install symfony/process v2.8.2|install symfony/process v2.8.20|install symfony/process v2.8.21|install symfony/process v2.8.22|install symfony/process v2.8.23|install symfony/process v2.8.24|install symfony/process v2.8.25|install symfony/process v2.8.26|install symfony/process v2.8.27|install symfony/process v2.8.28|install symfony/process v2.8.29|install symfony/process v2.8.3|install symfony/process v2.8.30|install symfony/process v2.8.31|install symfony/process v2.8.32|install symfony/process v2.8.4|install symfony/process v2.8.5|install symfony/process v2.8.6|install symfony/process v2.8.7|install symfony/process v2.8.8|install symfony/process v2.8.9|install symfony/process v3.0.0|install symfony/process v3.0.1|install symfony/process v3.0.2|install symfony/process v3.0.3|install symfony/process v3.0.4|install symfony/process v3.0.5|install symfony/process v3.0.6|install symfony/process v3.0.7|install symfony/process v3.0.8|install symfony/process v3.0.9|install symfony/process v3.1.0|install symfony/process v3.1.1|install symfony/process v3.1.10|install symfony/process v3.1.2|install symfony/process v3.1.3|install symfony/process v3.1.4|install symfony/process v3.1.5|install symfony/process v3.1.6|install symfony/process v3.1.7|install symfony/process v3.1.8|install symfony/process v3.1.9|install symfony/process v3.2.0|install symfony/process v3.2.1|install symfony/process v3.2.10|install symfony/process v3.2.11|install symfony/process v3.2.12|install symfony/process v3.2.13|install symfony/process v3.2.14|install symfony/process v3.2.2|install symfony/process v3.2.3|install symfony/process v3.2.4|install symfony/process v3.2.5|install symfony/process v3.2.6|install symfony/process v3.2.7|install symfony/process v3.2.8|install symfony/process v3.2.9|install symfony/process v3.3.14
- laravel/valet v2.0.0 requires symfony/process ~2.7|~3.0 -> satisfiable by symfony/process[v2.7.0, v2.7.1, v2.7.10, v2.7.11, v2.7.12, v2.7.13, v2.7.14, v2.7.15, v2.7.16, v2.7.17, v2.7.18, v2.7.19, v2.7.2, v2.7.20, v2.7.21, v2.7.22, v2.7.23, v2.7.24, v2.7.25, v2.7.26, v2.7.27, v2.7.28, v2.7.29, v2.7.3, v2.7.30, v2.7.31, v2.7.32, v2.7.33, v2.7.34, v2.7.35, v2.7.36, v2.7.37, v2.7.38, v2.7.39, v2.7.4, v2.7.5, v2.7.6, v2.7.7, v2.7.8, v2.7.9, v2.8.0, v2.8.1, v2.8.10, v2.8.11, v2.8.12, v2.8.13, v2.8.14, v2.8.15, v2.8.16, v2.8.17, v2.8.18, v2.8.19, v2.8.2, v2.8.20, v2.8.21, v2.8.22, v2.8.23, v2.8.24, v2.8.25, v2.8.26, v2.8.27, v2.8.28, v2.8.29, v2.8.3, v2.8.30, v2.8.31, v2.8.32, v2.8.4, v2.8.5, v2.8.6, v2.8.7, v2.8.8, v2.8.9, v3.0.0, v3.0.1, v3.0.2, v3.0.3, v3.0.4, v3.0.5, v3.0.6, v3.0.7, v3.0.8, v3.0.9, v3.1.0, v3.1.1, v3.1.10, v3.1.2, v3.1.3, v3.1.4, v3.1.5, v3.1.6, v3.1.7, v3.1.8, v3.1.9, v3.2.0, v3.2.1, v3.2.10, v3.2.11, v3.2.12, v3.2.13, v3.2.14, v3.2.2, v3.2.3, v3.2.4, v3.2.5, v3.2.6, v3.2.7, v3.2.8, v3.2.9, v3.3.0, v3.3.1, v3.3.10, v3.3.11, v3.3.12, v3.3.13, v3.3.14, v3.3.2, v3.3.3, v3.3.4, v3.3.5, v3.3.6, v3.3.7, v3.3.8, v3.3.9, v3.4.0, v3.4.1].
- Can only install one of: symfony/process[v3.3.0, v4.0.1].
- Can only install one of: symfony/process[v3.3.1, v4.0.1].
- Can only install one of: symfony/process[v3.3.10, v4.0.1].
- Can only install one of: symfony/process[v3.3.11, v4.0.1].
- Can only install one of: symfony/process[v3.3.12, v4.0.1].
- Can only install one of: symfony/process[v3.3.13, v4.0.1].
- Can only install one of: symfony/process[v3.3.2, v4.0.1].
- Can only install one of: symfony/process[v3.3.3, v4.0.1].
- Can only install one of: symfony/process[v3.3.4, v4.0.1].
- Can only install one of: symfony/process[v3.3.5, v4.0.1].
- Can only install one of: symfony/process[v3.3.6, v4.0.1].
- Can only install one of: symfony/process[v3.3.7, v4.0.1].
- Can only install one of: symfony/process[v3.3.8, v4.0.1].
- Can only install one of: symfony/process[v3.3.9, v4.0.1].
- Installation request for symfony/process (locked at v4.0.1) -> satisfiable by symfony/process[v4.0.1].


Installation failed, reverting ./composer.json to its original content.

这到底发生了什么,为什么我不能在全球范围内安装代客?我意识到这可能是某种依赖性问题/冲突,但对我来说没有意义。

4 个答案:

答案 0 :(得分:0)

查看https://stackoverflow.com/a/27754096以查看已安装软件包的列表 - symfony/console是否已在4.0.1版中列出? Lavarel安装程序明确要求symfony/console的v2.3或v3.x,因此您可能必须先通过symfony/console手动删除composer global remove symfony/console - 或者至少查看composer global why symfony/console }了解为什么symfony/console在该版本中安装

答案 1 :(得分:0)

Installation request for symfony/console (locked at v4.0.1, required as ^4.0)

Installation request for symfony/process (locked at v4.0.1)

Your symfony/console and symfony/process packages are locked at v4.0.1 (as per your composer.lock file), and you're trying to install the laravel/valet package which requires symfony/process ~2.7|~3.0 as per:

$ composer show -a laravel/valet 2.0.6 | grep ^symfony
symfony/process ~2.7|~3.0

However you can only install one branch as per the following message:

Can only install one of: symfony/process[v3.3.x, v4.0.x].

So to see, which existing packages locked it (e.g. symfony/process), run:

composer global why symfony/process -t

Or upgrade to the latest laravel/valet (v2.0.8) which now supports symfony/process ~4.0:

$ composer show -a laravel/valet | grep ^symfony
symfony/process ~2.7|~3.0|~4.0

See also: How to resolve a "Can only install one of:" conflict?

答案 2 :(得分:0)

对于遇到相同问题的任何人,我知道我已经两年了,但是以防万一有人仍然遇到此问题,请转到您的Composer文件夹

/ users / [name] / AppData / Roaming / Composer

将所有内容从该文件​​夹移动到临时文件夹以进行备份。只要确保您移动(剪切和粘贴),不要复制。该文件夹需要清空。

然后

composer global require laravel/valet

鲍勃是你的叔叔。

答案 3 :(得分:0)

检查这个Github问题,它解决了我的问题: https://github.com/laravel/valet/issues/489#event-1390815851

简而言之,只需尝试使用cgr(= composer global require)即可解决。打开终端

composer global require consolidation/cgr
//then update your $PATH, mine working on Catalina 10.15.4
echo 'export PATH="$(composer config -g home)/vendor/bin:$PATH"' >> ~/.zshrc
//then you should be able to use cgr to install laravel/valet
cgr laravel/valet