Remove dependency on packaging Python package
Signed-off-by: Jan Musial <jan.musial@intel.com>
This commit is contained in:
parent
b0a3c9cd45
commit
aa895fe20c
@ -1,2 +1 @@
|
|||||||
packaging>=20.3
|
|
||||||
PyYAML>=6.0
|
PyYAML>=6.0
|
||||||
|
11
utils/casctl
11
utils/casctl
@ -4,15 +4,16 @@
|
|||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
#
|
#
|
||||||
|
|
||||||
from packaging import version
|
|
||||||
import platform
|
import platform
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
min_ver = version.parse("3.6")
|
min_ver = "3.6"
|
||||||
ver = version.parse(platform.python_version())
|
ver = platform.python_version()
|
||||||
if ver < min_ver:
|
if ver < min_ver:
|
||||||
print((f"Minimum required python version is {min_ver}\n"
|
print("Minimum required python version is {}. Detected python version is {}".format(
|
||||||
f"Detected python version is {ver}"),
|
min_ver,
|
||||||
|
ver,
|
||||||
|
),
|
||||||
file = sys.stderr)
|
file = sys.stderr)
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user