简体   繁体   中英

Invalid version string "*"

Here is the line that causes the issue:

"config": {
    "platform": {
        "ext-calendar": "*"
    }
},

And on composer update it results in a Invalid version string "*"

Composer version: 1.9.3

Tried to remove the vendor and re-install everything, but same results.

In your composer.json, you can add platform into your config, to force it to resolve dependencies to a specific version of PHP.

https://getcomposer.org/doc/06-config.md#platform

"config": {
    "platform": {
        "php": "5.6"
    },
},

You use this platform key if for example your dev machine has a different version of PHP than your actual server, so that composer resolves the dependencies to the specific version. This means having * in here doesn't make sense. Also, that's a PHP extension, not a PHP version, so it just belongs in the normal require section, where a * is accepted.

Either delete that section, or lock down an actual PHP number, and you should be good to go.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM