Skip to content

Commit

Permalink
fix version parsing (#985)
Browse files Browse the repository at this point in the history
  • Loading branch information
CSY-ModelCloud authored Jan 1, 2025
1 parent 244f17b commit 4f18747
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gptqmodel/models/loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def check_versions(model_class, requirements: List[str]):
for req in requirements:
pkg, operator, version_required = parse_requirement(req)
try:
installed_version = Version(pkg)
installed_version = version(pkg)
if not compare_versions(installed_version, version_required, operator):
raise ValueError(f"{model_class} requires version {req}, but current {pkg} version is {installed_version} ")
except PackageNotFoundError:
Expand Down

0 comments on commit 4f18747

Please sign in to comment.