Fix test incompatibility with python-3.7+
platform.linux_distribution was removed in python-3.7. Related: #2175198
This commit is contained in:
parent
5c9a2d488e
commit
a517fa496c
@ -156,11 +156,11 @@ def dist_release():
|
|||||||
"""
|
"""
|
||||||
Find out the release number of Linux distribution.
|
Find out the release number of Linux distribution.
|
||||||
"""
|
"""
|
||||||
dist = platform.linux_distribution()
|
dist = platform.release()
|
||||||
if not dist or dist[1] == "":
|
if not dist:
|
||||||
_print("WARN: dist_release() - Could not determine dist release")
|
_print("WARN: dist_release() - Could not determine dist release")
|
||||||
return None
|
return None
|
||||||
return dist[1]
|
return dist
|
||||||
|
|
||||||
|
|
||||||
def dist_ver():
|
def dist_ver():
|
||||||
|
Loading…
Reference in New Issue
Block a user