我得到了一个400坏请求连接在http上的问题,它似乎包只想要安装通过http。我尝试过在composer.json中进行覆盖,其他人也尝试过这样做,以强制使用https --但这似乎不起作用。我没躲在防火墙后面。Mac 10.10.3
发行:
composer diagnose
Checking composer.json: FAIL
the property name is required
the property description is required
No license specified, it is recommended to do so. For closed-source software you may use "proprietary" as license.
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: FAIL
[Composer\Downloader\TransportException] The "http://packagist.org/packages.json" file could not be downloaded (HTTP/1.1 400 Bad Request)
Checking https connectivity to packagist: OK
Checking github.com rate limit: OK
Checking disk free space: OK
Checking composer version: OK
[Composer\Downloader\TransportException]
The "http://packagist.org/p/provider-2013$c2596c5d04e7701561420666ba120ede9429a69c75b732a5a01b18ebb3d64e53.json" file could not be downloaded (HTTP/1.1 400 Bad Request) Composer.json
{
"repositories": [
{ "packagist": false }
,
{
"type": "composer",
"url": "https://packagist.org"
}
]
}作曲家版本1.0-dev (92faf1c7a83a73794fb914a990be435e1df373ca) 2015-07-14 12:37:15
发布于 2015-10-12 06:24:02
对我来说,退出Forticlient (杀毒/网络安全应用程序)删除了400个错误请求,并允许我通过composer下载laravel。
也许你有杀毒软件或类似的干扰。
我在MacOSX10.11上
发布于 2015-10-29 02:58:47
我也有同样的问题,我使用composer诊断-vvv
Checking git settings: Executing command (CWD): git config color.ui
OK
Checking http connectivity to packagist: Downloading http://packagist.org/packages.json
FAIL
[Composer\Downloader\TransportException] The "http://packagist.org/packages.json" file could not be downloaded (HTTP/1.1 400 Bad Request)因为我安装了Forticlient,停止它,一切都很好。
发布于 2016-09-01 15:26:20
我正在我的10.11.06上安装Yii2,解决方法如下。
在我的例子中,我不得不关闭一个应用程序(防病毒/网络安全应用程序)
FortiClient折叠关闭
然后再尝试发出composer命令。
composer global require "fxp/composer-asset-plugin:^1.2.0"https://stackoverflow.com/questions/31467219
复制相似问题