switched to ImportError over ModuleNotFoundError for python 3.4 and below
This commit is contained in:
@@ -79,7 +79,7 @@ def dist_name():
|
|||||||
# Python 3.8 and up way
|
# Python 3.8 and up way
|
||||||
import distro
|
import distro
|
||||||
name, version, _id = distro.linux_distribution()
|
name, version, _id = distro.linux_distribution()
|
||||||
except ModuleNotFoundError as e:
|
except ImportError as e:
|
||||||
# Python 3.7 and down way
|
# Python 3.7 and down way
|
||||||
import platform
|
import platform
|
||||||
name, version, _id = platform.linux_distribution()
|
name, version, _id = platform.linux_distribution()
|
||||||
|
|||||||
Reference in New Issue
Block a user