From a95ba6c51f7debd96389c2174362e1c84513d16f Mon Sep 17 00:00:00 2001 From: "Peter J. Holzer" Date: Sat, 6 May 2023 00:13:52 +0200 Subject: [PATCH] Backport to Python 3.6 --- clients/record_os_version | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/clients/record_os_version b/clients/record_os_version index d1f8206..eecf81c 100755 --- a/clients/record_os_version +++ b/clients/record_os_version @@ -5,7 +5,8 @@ import time import ltsdb_record -p = subprocess.run(["/usr/bin/lsb_release", "-ir"], capture_output=True, text=True) +p = subprocess.run(["/usr/bin/lsb_release", "-ir"], + stdout=subprocess.PIPE, universal_newlines=True) for ln in p.stdout.split("\n")[:-1]: m = re.match(r"(.*?)\s*:\s+(.*)", ln) if m: