Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 882816 Details for
Bug 1082830
RFE: add config option for how many versions of each package to mash
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch to let the "latest" config option be either an int or a boo
0001-Let-latest-be-an-int-or-a-bool.patch (text/plain), 2.02 KB, created by
Ralph Bean
on 2014-04-04 19:02:53 UTC
(
hide
)
Description:
Patch to let the "latest" config option be either an int or a boo
Filename:
MIME Type:
Creator:
Ralph Bean
Created:
2014-04-04 19:02:53 UTC
Size:
2.02 KB
patch
obsolete
>From 045ee777db400b301a6cb4eff931d344b5027249 Mon Sep 17 00:00:00 2001 >From: Ralph Bean <rbean@redhat.com> >Date: Fri, 4 Apr 2014 15:01:49 -0400 >Subject: [PATCH] Let latest be an int or a bool. > >--- > mash/__init__.py | 19 +++++++++++++++++-- > mash/config.py | 2 +- > 2 files changed, 18 insertions(+), 3 deletions(-) > >diff --git a/mash/__init__.py b/mash/__init__.py >index 997c0ce..f8f414d 100644 >--- a/mash/__init__.py >+++ b/mash/__init__.py >@@ -31,6 +31,7 @@ import arch as masharch > import multilib > import metadata > import yum >+import yum.config > > import rpmUtils.arch > >@@ -298,8 +299,22 @@ class Mash: > os.makedirs(self.config.cachedir, 0755) > # Get package list. This is an expensive operation. > self.logger.info("Getting package lists for %s..." % (self.config.tag)) >- >- (pkglist, buildlist) = self.session.listTaggedRPMS(self.config.tag, inherit = self.config.inherit, latest = self.config.latest, rpmsigs = True) >+ >+ # Latest may be an int or a bool. >+ # https://bugzilla.redhat.com/showdependencytree.cgi?id=1082830 >+ latest = self.config.latest >+ try: >+ latest = int(latest) >+ except ValueError: >+ latest = yum.config.BoolOption().parse(latest) >+ >+ (pkglist, buildlist) = self.session.listTaggedRPMS( >+ self.config.tag, >+ inherit=self.config.inherit, >+ latest=latest, >+ rpmsigs=True, >+ ) >+ > # filter by key > biglist = PackageList(self.config) > for pkg in pkglist: >diff --git a/mash/config.py b/mash/config.py >index 2b12034..fdf4254 100644 >--- a/mash/config.py >+++ b/mash/config.py >@@ -48,7 +48,7 @@ class MashConfig(config.BaseConfig): > delta_dirs = config.ListOption() > max_delta_rpm_size = config.Option(300000000) > make_ancient = config.BoolOption(False) >- latest = config.BoolOption(True) >+ latest = config.Option(True) > distro_tags = config.Option() > content_tags = config.ListOption() > prefer_ppc64 = config.BoolOption(False) >-- >1.9.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1082830
: 882816