chiark / gitweb /
build: fix str vs. bytes error in buildserverid
authorHans-Christoph Steiner <hans@eds.org>
Thu, 11 Jan 2018 11:28:49 +0000 (12:28 +0100)
committerHans-Christoph Steiner <hans@eds.org>
Thu, 11 Jan 2018 11:50:18 +0000 (12:50 +0100)
ERROR: Could not build app org.fdroid.fdroid due to unknown error: Traceback (most recent call last):
  File "/var/lib/jenkins/userContent/reproducible/reproducible_setup_fdroid_build_environment/fdroidserver/build.py", line 1202, in main
    options.onserver, options.refresh):
  File "/var/lib/jenkins/userContent/reproducible/reproducible_setup_fdroid_build_environment/fdroidserver/build.py", line 972, in trybuild
    build_server(app, build, vcs, build_dir, output_dir, log_dir, force)
  File "/var/lib/jenkins/userContent/reproducible/reproducible_setup_fdroid_build_environment/fdroidserver/build.py", line 82, in build_server
    logging.debug(_('Fetched buildserverid from VM: ') + buildserverid)
TypeError: Can't convert 'bytes' object to str implicitly

fdroidserver/build.py

index 39bde47b16c8fe8a96bed54d16fd739f3a4439c2..7e587c9b0d22c3af2a3e18366e3b479de706c708 100644 (file)
@@ -79,7 +79,8 @@ def build_server(app, build, vcs, build_dir, output_dir, log_dir, force):
             buildserverid = subprocess.check_output(['vagrant', 'ssh', '-c',
                                                      'cat /home/vagrant/buildserverid'],
                                                     cwd='builder').rstrip()
-            logging.debug(_('Fetched buildserverid from VM: ') + buildserverid)
+            logging.debug(_('Fetched buildserverid from VM: {buildserverid}')
+                          .format(buildserverid=buildserverid.decode()))
 
         # Open SSH connection...
         logging.info("Connecting to virtual machine...")