mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
vendor packaging.version (#114108)
Fixes #113940. This vendors the relevant parts of [`packaging==23.2.0`]() to have access to `Version` and `InvalidVersion` without taking a runtime dependency on `setuptools` or `packaging`. I didn't find any vendoring policy so I put it under `torch._vendor.packaging`. While I have only vendored the files we need, I have not touched or trimmed the files otherwise. Pull Request resolved: https://github.com/pytorch/pytorch/pull/114108 Approved by: https://github.com/malfet, https://github.com/albanD
This commit is contained in:
committed by
PyTorch MergeBot
parent
8ec59d3553
commit
2aa486de9b
5
setup.py
5
setup.py
@ -1117,11 +1117,6 @@ def main():
|
||||
"fsspec",
|
||||
]
|
||||
|
||||
if IS_WINDOWS and sys.version_info >= (3, 12, 0):
|
||||
# torch.version requires this and it is not part
|
||||
# of the default cpython install on windows in 3.12+
|
||||
install_requires.append("packaging")
|
||||
|
||||
# Parse the command line and check the arguments before we proceed with
|
||||
# building deps and setup. We need to set values so `--help` works.
|
||||
dist = Distribution()
|
||||
|
Reference in New Issue
Block a user