aboutcode-org / aboutcode-org/univers
`packaging.version` fails to parse legit PyPI package version
- 主要語言
- Python
- 星號
- 50
- 分支
- 29
- PR 合併指標
- 30 天內沒有已合併 PR
描述
`packaging.version` is unable to parse some PyPI package version.
Here’s an example for https://pypi.org/project/nltk/2.0.1rc2-git/, where `packaging` fails to parse the `nltk` version `2.0.1rc2-git`:
```python
>>> from packaging.version import Version
>>> Version("2.0.1rc2-git")
Traceback (most recent call last):
File "", line 1, in
File "/../venv/lib/python3.10/site-packages/packaging/version.py", line 202, in __init__
raise InvalidVersion(f"Invalid version: {version!r}")
packaging.version.InvalidVersion: Invalid version: '2.0.1rc2-git'
```
In light of this we should reconsider how we handle PyPI package versions in Univers. We can not rely on `packaging.version` for these cases.
貢獻指南
這個儲存庫沒有索引到貢獻指南
評估
這個 Issue 還沒有評估資料。