Library is partially non-compliant with semver spec
See original GitHub issueBreaking input: 0.0.0-0foo.1
Expected result:
>>> import semver
>>> semver.parse('0.0.0-0foo.1')
{'build': None, 'major': 0, 'patch': 0, 'minor': 0, 'prerelease': '0foo.1'}
Actual result:
>>> import semver
>>> semver.parse('0.0.0-0foo.1')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python3.5/dist-packages/semver.py", line 65, in parse
raise ValueError('%s is not valid SemVer string' % version)
ValueError: 0.0.0-0foo.1 is not valid SemVer string
Per item 9, only numeric IDs cannot contain leading zeros – since 0foo
is not entirely numeric, it may contain a leading zero.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Semver validation error when prerelease version contains a ...
I can't see any restriction about this in the semver documentation. ... Library is partially non-compliant with semver spec #114.
Read more >Semantic Versioning 2.0.0 | Semantic Versioning
Semantic Versioning Specification (SemVer) The key words “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”, “SHOULD NOT”, “RECOMMENDED”, “MAY”, ...
Read more >Phantom dependencies - language design - Rust Internals
According to the semver spec, addition of new backwards-compatible APIs requires incrementing the minor version. People are entirely justified ...
Read more >Reference — python-semanticversion latest documentation
Check whether a version string matches a specification string: >>> match('>=0.1.1', '0.1.2') ... For non- partial versions, compare using the SemVer scheme.
Read more >semver - npm Docs
semver. The semantic versioner for npm. Select CLI Version: ... A JavaScript implementation of the https://semver.org/ specification.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Any update on this? We use git commit hash as a prerelease part, so sometimes we trigger this error too.
Duplicate of #194 so closing.