revisor/base.py | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-)
New commits: commit 52146e267f5989d610f29a4dd12e873bcd60a76c Merge: 0fcfe45... 13b4835... Author: Jeroen van Meeuwen (Fedora Unity) <kana...@fedoraunity.org> Date: Mon Mar 9 23:23:33 2009 +0100 Merge branch 'master' of ssh://git.fedorahosted.org/git/revisor commit 0fcfe4584669e5749bc216201cdcc4007b10a430 Author: Jeroen van Meeuwen (Fedora Unity) <kana...@fedoraunity.org> Date: Mon Mar 9 23:21:31 2009 +0100 Make the package sack excludes actually apply Fix the routine to match packages in livecdtools kickstart package selection mode diff --git a/revisor/base.py b/revisor/base.py index fbeeb97..6de76ec 100644 --- a/revisor/base.py +++ b/revisor/base.py @@ -310,13 +310,21 @@ class RevisorBase: self.log.debug(_("Building a nice package list from ksdata, and adding it to the transaction"), level=6) - if self.cfg.kickstart_uses_pkgsack_exclude: for pkg in excludedList: self.cfg.yumobj.conf.exclude.append(pkg) self.log.debug(_("Using pkgsack excludes, the list of packages to exclude is now: %r") % self.cfg.yumobj.conf.exclude, level=9) + try: + if hasattr(self.cfg.yumobj,"_getSacks"): + self.cfg.yumobj._getSacks(archlist=self.cfg.arch_list) + else: + self.log.debug(_("Using deprecated YUM function: %s()") % "doSackSetup", level=7) + self.cfg.yumobj.doSackSetup(archlist=self.cfg.arch_list) + except: + pass + # Actually, let's figure out what mode we're in and call something once we know which way to go if self.cfg.mode_respin: @@ -433,11 +441,10 @@ class RevisorBase: # Populate a dict of package objects to their names for match in matches: - matchdict[match.name] = match - - # Get the newest results from the search - mysack = yum.packageSack.ListPackageSack(matches) - for match in mysack.returnNewestByNameArch(): + try: + match = self.cfg.yumobj.pkgSack.returnNewestByNameArch(match) + except: + pass current += 1.0 self.cfg.yumobj.tsInfo.addInstall(match) pbar.set_fraction(current/total) _______________________________________________ revisor-devel mailing list revisor-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/revisor-devel