From: norbert.bizet Date: Wed, 27 Jul 2022 14:53:39 +0000 (-0400) Subject: cloud: Fix #9366 type out and err as str rather that bytes X-Git-Tag: Beta-15.0.0~537 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5343207d5313ef45d365e574e974fc2f30ddb83c;p=thirdparty%2Fbacula.git cloud: Fix #9366 type out and err as str rather that bytes --- diff --git a/bacula/scripts/aws_cloud_driver.in b/bacula/scripts/aws_cloud_driver.in index f9a6d27fa..e63d7ab13 100755 --- a/bacula/scripts/aws_cloud_driver.in +++ b/bacula/scripts/aws_cloud_driver.in @@ -1,5 +1,5 @@ #!/usr/bin/env python2 -# -*- coding: utf-8 -*- +# -*- coding: utf-8 -*- # Bacula® - The Network Backup Solution @@ -108,7 +108,7 @@ def download(): try: logging.info("enter download") proc = Popen(["aws", "s3", "cp", - os.path.join(cloud_path, volume, part), "-", "--only-show-errors"], stderr=PIPE) + os.path.join(cloud_path, volume, part), "-", "--only-show-errors"], stderr=PIPE, universal_newlines=True) output,err = proc.communicate() logging.debug("download proc communicate output:{0} , err:{1}".format(output,err)) if err and err.find("An error occurred (InvalidObjectState) when calling the GetObject operation") != -1: