From a62a1e1d6273d1b2021b072603ee9ffc86afc5c5 Mon Sep 17 00:00:00 2001 From: Ulysses Souza Date: Thu, 16 Apr 2020 17:04:40 +0200 Subject: Add "distro" package This package implements the method 'platform.linux_distribution' removed in Python 3.8 Signed-off-by: Ulysses Souza --- compose/cli/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'compose/cli') diff --git a/compose/cli/utils.py b/compose/cli/utils.py index 931487a6..40bef165 100644 --- a/compose/cli/utils.py +++ b/compose/cli/utils.py @@ -9,6 +9,7 @@ import ssl import subprocess import sys +import distro import docker import six @@ -73,7 +74,7 @@ def is_mac(): def is_ubuntu(): - return platform.system() == 'Linux' and platform.linux_distribution()[0] == 'Ubuntu' + return platform.system() == 'Linux' and distro.linux_distribution()[0] == 'Ubuntu' def is_windows(): -- cgit v1.2.3