Skip to content

Commit 343ce83

Browse files
committed
update to fix test failuer
1 parent 5819b70 commit 343ce83

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Diff for: cpp_linter_hooks/util.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import logging
44
from typing import Optional
55

6+
from clang_tools.util import Version
67
from clang_tools.install import is_installed as _is_installed, install_tool
78

89

@@ -23,8 +24,10 @@ def is_installed(tool_name: str, version: str) -> Optional[Path]:
2324
if path.is_file():
2425
return path
2526

27+
# parse the user-input version as a string
28+
parsed_ver = Version(version)
2629
# also check using clang_tools
27-
path = _is_installed(tool_name, version)
30+
path = _is_installed(tool_name, parsed_ver)
2831
if path is not None:
2932
return Path(path)
3033

0 commit comments

Comments
 (0)