Composer Content-Length Mismatch

前端 未结 11 1588
暗喜
暗喜 2020-11-28 06:03

Sometimes when I run composer update to upgrade the laravel project, a content-length mismatch exception might occur. Finally, I get this is because of the terrible firewall

11条回答
  •  青春惊慌失措
    2020-11-28 07:00

    I had the same issue so I came here though google search.

    I run composer commands both on my local machine and docker machine. I received a variety of errors on each machine when running composer install including Composer Content-Length Mismatch.

    I started to mess with my composer.json file as recommended, then I realized the macbook lost it's wifi connection, like it loves to do. Additionally I am on a poor network as I am traveling. I also was warned my composer was out of date on my local machine, which I should have been using my docker VM to issue the commands anyway. My docker workspace container had not been updated for a year.

    I got the wifi connection back, upgraded composer on my local machine and composer install ran just fine. I assume if I upgrade docker config that it will work there as well.

提交回复
热议问题