composer / semver

Semantic versioning utilities with the addition of version constraints parsing and checking.
MIT License
3.15k stars 76 forks source link

bug: version normalize fails with 5 digit version numbers #23

Closed scholtz closed 9 years ago

scholtz commented 9 years ago

Returns Invalid version string "1.0.0.0.1".

The case is that custom pear packages may have this type of versions. The problem is in composer when tries to install this type of pear package that it fails because normalize function from this scripts fails and in consequence the package is skipped while adding to pear repository.

This is valid version and is comparable with function version_compare (http://php.net/manual/en/function.version-compare.php)

This type of versions are used by people.. For example if there is version of package 1.0.0, the package of translation of this package may be 1.0.0.1, later 1.0.0.2, and so on..

If this is not a bug, than there is bug in composer main package to use this semver also for pear repositories..

alcohol commented 9 years ago

PEAR is pretty much dead anyway. I'll ask @seldaek how we feel about supporting unconventional stuff like this, but I personally would say, we don't.

Seldaek commented 9 years ago

I'd tend to agree that indeed we don't need to support this. We already support 1.0.0.2 (4 components), but having more than that is such an edge case it's not really worth it IMO.