提问者:小点点

laravel/lumen安装程序的安装失败:guzzle HTTP/guzzle锁定在6.3。0


我试图通过命令composer global require“laravel/Lumen installer”安装Lumen,但在终端上抛出以下错误。

Changed current directory to /home/lykos/.config/composer
Using version ^1.0 for laravel/lumen-installer
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Conclusion: don't install laravel/lumen-installer v1.0.2
    - Conclusion: don't install laravel/lumen-installer v1.0.1
    - Installation request for symfony/console (locked at v4.0.3) -> satisfiable by symfony/console[v4.0.3].
    - Conclusion: remove guzzlehttp/guzzle 6.3.0
    - Installation request for laravel/lumen-installer ^1.0 -> satisfiable by laravel/lumen-installer[v1.0.0, v1.0.1, v1.0.2].
    - Conclusion: don't install guzzlehttp/guzzle 6.3.0
    - laravel/lumen-installer v1.0.0 requires guzzlehttp/guzzle ~4.0|~5.0 -> satisfiable by guzzlehttp/guzzle[4.0.0, 4.0.1, 4.0.2, 4.1.0, 4.1.1, 4.1.2, 4.1.3, 4.1.4, 4.1.5, 4.1.6, 4.1.7, 4.1.8, 4.2.0, 4.2.1, 4.2.2, 4.2.3, 4.2.4, 5.0.0, 5.0.1, 5.0.2, 5.0.3, 5.1.0, 5.2.0, 5.3.0, 5.3.1, 5.3.2].
    - Can only install one of: guzzlehttp/guzzle[4.0.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.0.1, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.0.2, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.1, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.2, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.3, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.4, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.5, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.6, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.7, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.1.8, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.2.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.2.1, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.2.2, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.2.3, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[4.2.4, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.0.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.0.1, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.0.2, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.0.3, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.1.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.2.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.3.0, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.3.1, 6.3.0].
    - Can only install one of: guzzlehttp/guzzle[5.3.2, 6.3.0].
    - Installation request for guzzlehttp/guzzle (locked at 6.3.0) -> satisfiable by guzzlehttp/guzzle[6.3.0].


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

在谷歌搜索中,我试着这样做rm-R~/。作曲家/供应商/古兹http

但抛出一个错误,因为没有这样的目录

rm:无法删除'/home/lykos/。作曲家/供应商/guzzlehttp':没有这样的文件或目录

我的~/。config/composer/composer。json文件如下所示

{
    "require": {
        "laravel/installer": "^1.5"
    }
}

有没有办法解决这个问题?


共3个答案

匿名用户

泰勒在v1中修复了这个问题。0.3,但尚未对其进行标记,因此您可以安装dev master以获得更新版本:composer global require laravel/lumen安装程序:dev master

匿名用户

尝试删除全局~/。编写器目录。首先安装lumen/installer,然后安装laravel/installerglobal。对我来说很好。

匿名用户

laravel/lumen安装程序v1.0.0需要guzzlehttp/guzzlehttp~4.0|~5.0

guzzle的安装请求http/guzzle(锁定在6.3.0

这意味着guzzlehttp/guzzlehttp被锁定在6.3.0,根据您的composer.lock文件,并且您的包(laravel/lumen-Inster)需要guzzlehttp/guzzle~4.0|~5.0。通过grep 6.3.0~/。作曲家/composer.lock命令检查它。

因此,您需要删除guzzlehttp/guzzlehttp从您的~/.作曲家/composer.json按照建议:

结论:删除guzzle http/guzzle6.3。0

否则,如果它不在那里,您需要删除依赖它的软件包,或者将laravel/lumen安装程序升级到v1。0.3(如前所述)。例如。

composer global require laravel/lumen-installer:^1.0.3

要查看依赖树(什么是使用不同版本的guzzer),您可以运行:

composer global show -t

另请参见:如何解决“只能安装其中一个:”的冲突?