gpt4 book ai didi

php - Composer 安装 "Failed to open stream"

转载 作者:行者123 更新时间:2023-12-04 02:03:46 25 4
gpt4 key购买 nike

每当我运行安装程序,甚至手动安装 Composer 时,我都会收到一个错误,不允许我完成安装,这很烦人。在 Laragon 中,一个程序用于使用 composer 及其包创建许多不同的项目。它不允许我使用 Laravel,因为 Composer 将无法正确安装和运行。

错误是:

The "https://getcomposer.org/versions" file could not be downloaded: failed to open stream: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

The "https://getcomposer.org/download/1.4.2/composer.phar.sig" file could not be downloaded: failed to open stream: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

最佳答案

了解错误是IPV6网络错误

  • 首先,我更新了运行此命令的 Composer 的版本

    composer -vvv self 更新

  • 我还遵循了 composer 文档中有关解决 IPV6 超时问题的说明

https://getcomposer.org/doc/articles/troubleshooting.md#operation-timed-out-ipv6-issues-

我不能说是哪一个产生了魔力

关于php - Composer 安装 "Failed to open stream",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45225073/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com