Blame SOURCES/BZ-1600383-save-ts-no-str-concat.patch

6e3a62
diff -up yum-3.4.3/yum/__init__.py.orig yum-3.4.3/yum/__init__.py
6e3a62
--- yum-3.4.3/yum/__init__.py.orig	2019-03-27 16:56:28.012138396 +0100
6e3a62
+++ yum-3.4.3/yum/__init__.py	2019-03-27 16:58:37.176809731 +0100
6e3a62
@@ -6890,24 +6890,24 @@ much more problems).
6e3a62
         
6e3a62
         self._ts_save_file = filename
6e3a62
         
6e3a62
-        msg = "%s\n" % self.rpmdb.simpleVersion(main_only=True)[0]
6e3a62
-        msg += "%s\n" % self.ts.getTsFlags()
6e3a62
+        msg = ["%s\n" % self.rpmdb.simpleVersion(main_only=True)[0],
6e3a62
+               "%s\n" % self.ts.getTsFlags()]
6e3a62
 
6e3a62
         if self.tsInfo._pkgSack is None: # Transactions have pkgSack?
6e3a62
-            msg += "1\n"
6e3a62
+            msg += ["1\n"]
6e3a62
         else:
6e3a62
-            msg += "%s\n" % (len(self.repos.listEnabled()) + 1)
6e3a62
+            msg += ["%s\n" % (len(self.repos.listEnabled()) + 1)]
6e3a62
             for r in self.repos.listEnabled():
6e3a62
-                msg += "%s:%s:%s\n" % (r.id, len(r.sack), r.repoXML.revision)
6e3a62
+                msg += ["%s:%s:%s\n" % (r.id, len(r.sack), r.repoXML.revision)]
6e3a62
 
6e3a62
         # Save what we think the future rpmdbv will be.
6e3a62
-        msg += "%s:%s\n" % ('installed', self.tsInfo.futureRpmDBVersion())
6e3a62
+        msg += ["%s:%s\n" % ('installed', self.tsInfo.futureRpmDBVersion())]
6e3a62
 
6e3a62
-        msg += "%s\n" % len(self.tsInfo.getMembers())
6e3a62
+        msg += ["%s\n" % len(self.tsInfo.getMembers())]
6e3a62
         for txmbr in self.tsInfo.getMembers():
6e3a62
-            msg += txmbr._dump()
6e3a62
+            msg += [txmbr._dump()]
6e3a62
         try:
6e3a62
-            f.write(msg)
6e3a62
+            f.write(''.join(msg))
6e3a62
             f.close()
6e3a62
         except (IOError, OSError), e:
6e3a62
             self._ts_save_file = None
6e3a62
diff -up yum-3.4.3/yum/transactioninfo.py.orig yum-3.4.3/yum/transactioninfo.py
6e3a62
--- yum-3.4.3/yum/transactioninfo.py.orig	2019-03-27 16:55:57.905748837 +0100
6e3a62
+++ yum-3.4.3/yum/transactioninfo.py	2019-03-27 16:58:37.178809757 +0100
6e3a62
@@ -873,44 +873,47 @@ class TransactionMember:
6e3a62
         return "<%s : %s (%s)>" % (self.__class__.__name__, str(self),hex(id(self))) 
6e3a62
     
6e3a62
     def _dump(self):
6e3a62
-        msg = "mbr: %s,%s,%s,%s,%s %s\n" % (self.name, self.arch, self.epoch, 
6e3a62
-                     self.version, self.release, self.current_state)
6e3a62
-        msg += "  repo: %s\n" % self.po.repo.id
6e3a62
-        msg += "  ts_state: %s\n" % self.ts_state
6e3a62
-        msg += "  output_state: %s\n" %  self.output_state
6e3a62
-        msg += "  isDep: %s\n" %  bool(self.isDep)
6e3a62
-        msg += "  reason: %s\n" % self.reason
6e3a62
-        #msg += "  process: %s\n" % self.process
6e3a62
-        msg += "  reinstall: %s\n" % bool(self.reinstall)
6e3a62
+        msg = ["mbr: %s,%s,%s,%s,%s %s\n" %
6e3a62
+               (self.name, self.arch, self.epoch, self.version, self.release,
6e3a62
+                self.current_state),
6e3a62
+               "  repo: %s\n" % self.po.repo.id,
6e3a62
+               "  ts_state: %s\n" % self.ts_state,
6e3a62
+               "  output_state: %s\n" %  self.output_state,
6e3a62
+               "  isDep: %s\n" %  bool(self.isDep),
6e3a62
+               "  reason: %s\n" % self.reason,
6e3a62
+        #       "  process: %s\n" % self.process,
6e3a62
+               "  reinstall: %s\n" % bool(self.reinstall)]
6e3a62
         
6e3a62
         if self.relatedto:
6e3a62
-            msg += "  relatedto:"
6e3a62
+            msg += ["  relatedto:"]
6e3a62
             for (po, rel) in self.relatedto:
6e3a62
                 pkgorigin = 'a'
6e3a62
                 if isinstance(po, YumInstalledPackage):
6e3a62
                     pkgorigin = 'i'
6e3a62
-                msg += " %s,%s,%s,%s,%s@%s:%s" % (po.name, po.arch, po.epoch, 
6e3a62
-                      po.version, po.release, pkgorigin, rel)
6e3a62
-            msg += "\n"
6e3a62
+                msg += [" %s,%s,%s,%s,%s@%s:%s" %
6e3a62
+                        (po.name, po.arch, po.epoch, po.version, po.release,
6e3a62
+                         pkgorigin, rel)]
6e3a62
+            msg += ["\n"]
6e3a62
             
6e3a62
         for lst in ['depends_on', 'obsoletes', 'obsoleted_by', 'downgrades',
6e3a62
                     'downgraded_by', 'updates', 'updated_by']:
6e3a62
             thislist = getattr(self, lst)
6e3a62
             if thislist:
6e3a62
-                msg += "  %s:" % lst
6e3a62
+                msg += ["  %s:" % lst]
6e3a62
                 for po in thislist:
6e3a62
                     pkgorigin = 'a'
6e3a62
                     if isinstance(po, YumInstalledPackage):
6e3a62
                         pkgorigin = 'i'
6e3a62
-                    msg += " %s,%s,%s,%s,%s@%s" % (po.name, po.arch, po.epoch, 
6e3a62
-                        po.version, po.release, pkgorigin)
6e3a62
-                msg += "\n"
6e3a62
+                    msg += [" %s,%s,%s,%s,%s@%s" %
6e3a62
+                            (po.name, po.arch, po.epoch, po.version,
6e3a62
+                             po.release, pkgorigin)]
6e3a62
+                msg += ["\n"]
6e3a62
                 
6e3a62
         if self.groups:
6e3a62
-            msg += "  groups: %s\n" % ' '.join(self.groups)
6e3a62
+            msg += ["  groups: %s\n" % ' '.join(self.groups)]
6e3a62
         if self.environments:
6e3a62
-            msg += "  environments: %s\n" % ' '.join(self.environments)
6e3a62
+            msg += ["  environments: %s\n" % ' '.join(self.environments)]
6e3a62
         if self.repopkg:
6e3a62
-            msg += "  repopkg: %s\n" % self.repopkg
6e3a62
+            msg += ["  repopkg: %s\n" % self.repopkg]
6e3a62
 
6e3a62
-        return msg
6e3a62
+        return ''.join(msg)