]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
patman: Avoid circular dependency between command and tools
authorSimon Glass <sjg@chromium.org>
Sun, 7 Jun 2020 12:45:46 +0000 (06:45 -0600)
committerSimon Glass <sjg@chromium.org>
Fri, 10 Jul 2020 00:57:21 +0000 (18:57 -0600)
This seems to cause problems in some cases. Split the dependency by
copying the code to command.

Reported-by: Stefan Bosch <stefan_b@posteo.net>
Signed-off-by: Simon Glass <sjg@chromium.org>
tools/patman/command.py

index e67ac159e5a0e9cfe401244f43c185c788766011..bf8ea6c8c3c51f4df733640abb3959751c2abee0 100644 (file)
@@ -5,7 +5,6 @@
 import os
 
 from patman import cros_subprocess
-from patman import tools
 
 """Shell command ease-ups for Python."""
 
@@ -35,9 +34,9 @@ class CommandResult:
 
     def ToOutput(self, binary):
         if not binary:
-            self.stdout = tools.ToString(self.stdout)
-            self.stderr = tools.ToString(self.stderr)
-            self.combined = tools.ToString(self.combined)
+            self.stdout = self.stdout.decode('utf-8')
+            self.stderr = self.stderr.decode('utf-8')
+            self.combined = self.combined.decode('utf-8')
         return self