silverStripe使用作曲家,这将显示[Composer \ Downloader \ TransportException]

时间:2018-11-15 10:54:55

标签: composer-php silverstripe-4

我分别设置了我的AMP堆栈。使用Windows安装程序安装了作曲家,并将作曲家的php.exe设置为“ c:/php/php.exe”,即php.exe所在的位置。 进行File "C:\Users\AlexQuiñonez\AppData\Local\Programs\Python\Python37-32\Scripts\pyinstaller-script.py", line 1 SyntaxError: Non-UTF-8 code starting with '\xf1' in file C:\Users\AlexQuiñonez\AppData\Local\Programs\Python\Python37-32\Scripts\pyinstaller-script.py on line 1, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details 返回  [Composer \ Downloader \ TransportException]   内容长度不匹配,在预期的1069991中接收到515115字节

我该如何解决..?

1 个答案:

答案 0 :(得分:2)

这是Packagist镜像之一的问题。同时应解决此问题,但是如果仍然遇到此问题,https://github.com/composer/composer/issues/7782#issuecomment-438585301包含一些背景信息,并提供此命令以将镜像切换为使用:

composer config repositories.packagist.org composer https://repo-eu-uk-1.packagist.org

您以后可以使用以下命令取消设置镜像:

composer config repositories.packagist.org --unset