Could not load package intervention/image
Hello,
Since a random commit, I'm getting this error while trying to get intervention/image via composer:
[RuntimeException]
Could not load package intervention/image in http://packagist.org: [Unexpec
tedValueException] Could not parse version constraint 4.x.x: Invalid versio
n string "4.x.x"
It started in the following build: https://travis-ci.org/AsgardCms/Media/builds/94138842 A commit that has nothing to do with intervention, in my composer.json file I still have:
"intervention/image": "^2.3",
And the odd part is that it does not show up in php7.
Does anyone have any idea what the cause could be ?
Thank you,
Several people (https://github.com/Intervention/image/issues/467, https://github.com/Intervention/image/issues/464) mentioned this problem, but I still don't know what's the cause or if this is a Composer issue.
Oh ok, thanks for answering so fast, multiple people have reported this on the asgardcms slack channel, and had no idea why it was trying 4.x.x. Especially when I couldn't re-produce the issue locally.
"Good" to know it's not an isolated issue.
I have added a composer self-update as before_install script, and the build is back to green.
Thanks again
Hi,
I think the problem comes from the past. Every release before the comit 6783515d00135a567db3bcfdeb784e3f2da00733 includes a bad version format for illuminate/support (that's where the "4.x.x" comes from).
Even if those old release ain't used anymore, they are still in packagist. This is a problem for the people that are using packagist proxy for instance, because according to the configuration, all the releases (including the old one) could be downloaded.
I think getting rid of the old releases might be the only way to solve this issue.
@rfussien You might be right. The question is, what may cause more problems? Removing old packagist versions before 1.4.1 or letting people update composer.
I removed some tags for another project and packagist re-index just fine and on the composer side as well. But you're right, more feedback about it would be great.
Even I had the same problem. but when I update the composer using composer self-update. after I tried the composer update command it did n't throw any error.
Right, when it's about composer itself, a self-update does the job and it's easy (btw, I used to add this as a dailycron for non-production env).
But when it comes to satis/toran, the problem is there as well. First I tried to purge the "proxyfied" package and it produced a modification of the shasum (cf https://github.com/composer/composer/issues/2540), which produced a composer.lock corruption in all my projects. So I had to update all of them. Anyway, big waste of time for a small problem.
That's why I suggested a deletion for the releases older than 1.4.
Had the same problem, ran composer self-update and the problem went away. Strange.
composer self-update solved it for me too! :+1:
I'm getting this issue with travis ci. is anyone else getting it there. On my local machine its not the issue https://travis-ci.org/Core-Tech-Labs/LAZ/jobs/96394293
@RudyJessop Did you run composer self-update?
@DanielRTRD no shit it worked
The same here , the problem solved by running composer self-update
Thank you. self-update worked for me too.