我的composer.json
:
{
"require": {
"fxp/composer-asset-plugin": "~1.1.1"
}
}
当我跑
php -r "readfile('https://packagist.phpcomposer.com/packages.json');" > composer-setup.php
PHP Warning: readfile(https://packagist.phpcomposer.com/packages.json): failed to open stream: Operation now in progress in Command line code on line 1
我运行花药代码
LiuZeXin:GA xin$ composer global require "fxp/composer-asset-plugin:~1.1.1"
Changed current directory to /Users/xin/.composer
./composer.json has been updated
Loading composer repositories with package information
Installation failed, reverting ./composer.json to its original content.
[Composer\Downloader\TransportException]
**The "https://packagist.phpcomposer.com/packages.json" file could not be downloaded: failed to open stream: Operation now in progress**
require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--] [<packages>]...
我认为这是关于 php.ini 中的一些配置参数错误。
我需要帮助。
我更改了 php.ini 中的参数。
default_socket_timeout = 60
这对我有用。
谁能告诉我这个问题的原因?
@liuzexin thaaaanks! 我不敢相信它奏效了。
我更改了 php.ini 中的参数。
default_socket_timeout = 60
这对我有用。谁能告诉我这个问题的原因?
这对我也有效。 不要介意我的回答。 我只是想把我自己的足迹放在这个线程中,以防我再次遇到它。
最有用的评论
我更改了 php.ini 中的参数。
default_socket_timeout = 60
这对我有用。
谁能告诉我这个问题的原因?