[yum] Update to latest HEAD.
Zdeněk Pavlas
zpavlas at fedoraproject.org
Wed Jun 12 09:16:50 UTC 2013
commit af01fd19d8dd54f4c7de6e95b71067ec7f93c469
Author: Zdenek Pavlas <zpavlas at redhat.com>
Date: Wed Jun 12 11:16:35 2013 +0200
Update to latest HEAD.
- downloadonly: prefetch also pkg checksums. BZ 973380
- Fix superfluous dots after "via" in man pages. BZ 972764
- support "proxy = libproxy" syntax to enable libproxy. BZ 857263
- checkEnabledRepo: run prereposetup if necessary. BZ 826096
yum-HEAD.patch | 553 +++++++++++++++++++++++++++++++-------------------------
yum.spec | 9 +-
2 files changed, 315 insertions(+), 247 deletions(-)
---
diff --git a/yum-HEAD.patch b/yum-HEAD.patch
index 6d2adae..0e50416 100644
--- a/yum-HEAD.patch
+++ b/yum-HEAD.patch
@@ -2682,7 +2682,7 @@ index 0000000..2af059d
+ the mailing list, yum at lists.baseurl.org, or consult bugzilla.
+.fi
diff --git a/docs/yum.8 b/docs/yum.8
-index 1a8202a..76bbdd5 100644
+index 1a8202a..1c6a27b 100644
--- a/docs/yum.8
+++ b/docs/yum.8
@@ -25,6 +25,8 @@ gnome\-packagekit application\&.
@@ -2862,9 +2862,9 @@ index 1a8202a..76bbdd5 100644
+.br
+"+" = Package isn't installed, but will be the next time you run "yum upgrade" or "yum group upgrade foo"
+.br
-+" " = Package is installed, but wasn't installed via. the group (so "group remove foo" won't remove it).
++" " = Package is installed, but wasn't installed via the group (so "group remove foo" won't remove it).
+.br
-+"=" = Package is installed, and was installed via. the group.
++"=" = Package is installed, and was installed via the group.
+
+"\fBgroup summary\fP" is used to give a quick summary of how many groups
+are installed and available.
@@ -3041,7 +3041,7 @@ index 1a8202a..76bbdd5 100644
transaction 246).
+The redo command can also take some optional arguments before you specify the
+transaction. "force-reinstall" tells it reinstall any packages that were
-+installed in that transaction (via. install, upgrade or downgrade).
++installed in that transaction (via install, upgrade or downgrade).
+"force-remove" tells it to forcibly remove any packages that were updated or
+downgraded.
@@ -3055,20 +3055,21 @@ index 1a8202a..76bbdd5 100644
A (if it is not still installed), and "rollback 1" will try to remove packages
B and C. Note that after a "rollback 1" you will have a fourth transaction,
although the ending rpmdb version (see: yum version) should be the same in
-@@ -349,6 +516,12 @@ transactions 1 and 4.
+@@ -349,13 +516,20 @@ transactions 1 and 4.
The addon-info command takes a transaction ID, and the packages-list command
takes a package (with wildcards).
+-In "history list" you can change the behaviour of the 2nd column via. the
+The stats command shows some statistics about the current history DB.
+
+The sync commands allows you to change the rpmdb/yumdb data stored for any
+installed packages, to whatever is in the current rpmdb/yumdb (this is mostly
+useful when this data was not stored when the package went into the history DB).
+
- In "history list" you can change the behaviour of the 2nd column via. the
++In "history list" you can change the behaviour of the 2nd column via the
configuration option history_list_view.
-@@ -356,6 +529,7 @@ In "history list" output the Altered column also gives some extra information
+ In "history list" output the Altered column also gives some extra information
if there was something not good with the transaction (this is also shown at the
end of the package column in the packages-list command).
@@ -3086,7 +3087,7 @@ index 1a8202a..76bbdd5 100644
+This command will re-load a saved yum transaction file, this allows you to
+run a transaction on one machine and then use it on another.
+The two common ways to get a saved yum transaction file are from
-+"yum -q history addon-info last saved_tx" or via. the automatic saves in
++"yum -q history addon-info last saved_tx" or via the automatic saves in
+$TMPDIR/yum_save_tx.* when a transaction is solved but not run.
+
+Running the command without an argument, or a directory as an argument will
@@ -3274,9 +3275,18 @@ index 1a8202a..76bbdd5 100644
List the packages installed on the system that are obsoleted by packages
in any yum repository listed in the config file.
diff --git a/docs/yum.conf.5 b/docs/yum.conf.5
-index 515aa73..eccfa38 100644
+index 515aa73..d8d60a5 100644
--- a/docs/yum.conf.5
+++ b/docs/yum.conf.5
+@@ -64,7 +64,7 @@ options are: 'critical', 'emergency', 'error', 'warn' and 'debug'.
+ .IP
+ \fBprotected_packages\fR
+ This is a list of packages that yum should never completely remove. They are
+-protected via. Obsoletes as well as user/plugin removals.
++protected via Obsoletes as well as user/plugin removals.
+
+ The default is: yum glob:/etc/yum/protected.d/*.conf
+ So any packages which should be protected can do so by including a file in
@@ -114,15 +114,27 @@ are causing problems from the transaction.
Either `1' or `0'. Determines whether or not yum prompts for confirmation of
critical actions. Default is `0' (do prompt).
@@ -3333,6 +3343,15 @@ index 515aa73..eccfa38 100644
.IP
\fBexactarch\fR
Either `1' or `0'. Set to `1' to make yum update only update the architectures
+@@ -161,7 +180,7 @@ will also apply to kernel-debug-devel, etc.
+ Number of packages listed in installonlypkgs to keep installed at the same
+ time. Setting to 0 disables this feature. Default is '0'. Note that this
+ functionality used to be in the "installonlyn" plugin, where this option was
+-altered via. tokeep.
++altered via tokeep.
+ Note that as of version 3.2.24, yum will now look in the yumdb for a installonly
+ attribute on installed packages. If that attribute is "keep", then they will
+ never be removed.
@@ -188,12 +207,32 @@ Default is `true'.
Command-line option: \fB\-\-obsoletes\fP
@@ -3477,7 +3496,18 @@ index 515aa73..eccfa38 100644
\fBhistory_record \fR
Boolean - should yum record history entries for transactions. This takes some
disk space, and some extra time in the transactions. But it allows how to know a
-@@ -438,6 +551,31 @@ It's also possible to use the word "never", meaning that the metadata will
+@@ -391,7 +504,9 @@ syslog logging is disabled. Default is `/dev/log'.
+
+ .IP
+ \fBproxy \fR
+-URL to the proxy server that yum should use.
++URL to the proxy server that yum should use. Set this to `libproxy'
++to enable proxy auto configuration via libproxy. Defaults to direct
++connection.
+
+ .IP
+ \fBproxy_username \fR
+@@ -438,6 +553,31 @@ It's also possible to use the word "never", meaning that the metadata will
never expire. Note that when using a metalink file the metalink must always
be newer than the metadata for the repository, due to the validation, so this
timeout also applies to the metalink file.
@@ -3509,7 +3539,7 @@ index 515aa73..eccfa38 100644
.IP
\fBmirrorlist_expire \fR
-@@ -480,6 +618,19 @@ not listed above is the other metadata, which contains the changelog information
+@@ -480,6 +620,19 @@ not listed above is the other metadata, which contains the changelog information
which is used by yum-changelog. This is what "yum makecache" uses.
.IP
@@ -3529,7 +3559,7 @@ index 515aa73..eccfa38 100644
\fBmultilib_policy \fR
Can be set to 'all' or 'best'. All means install all possible arches for any package you
want to install. Therefore yum install foo will install foo.i386 and foo.x86_64 on x86_64,
-@@ -523,6 +674,13 @@ Default is `normal'.
+@@ -523,6 +676,13 @@ Default is `normal'.
See color_list_installed_older for possible values.
.IP
@@ -3543,7 +3573,7 @@ index 515aa73..eccfa38 100644
\fBcolor_list_installed_extra \fR
The colorization/highlighting for packages in list/info installed which has
no available package with the same name and arch.
-@@ -558,6 +716,13 @@ Default is `bold,underline,green.
+@@ -558,6 +718,13 @@ Default is `bold,underline,green.
See color_list_installed_older for possible values.
.IP
@@ -3557,7 +3587,7 @@ index 515aa73..eccfa38 100644
\fBcolor_search_match \fR
The colorization/highlighting for text matches in search.
Default is `bold'.
-@@ -587,14 +752,65 @@ be downloaded. The updates list is what is printed when you run "yum update",
+@@ -587,14 +754,65 @@ be downloaded. The updates list is what is printed when you run "yum update",
Default is `normal'.
See color_list_installed_older for possible values.
@@ -3623,7 +3653,7 @@ index 515aa73..eccfa38 100644
.SH "[repository] OPTIONS"
-@@ -702,12 +918,18 @@ key will be automatically imported without user confirmation.
+@@ -702,12 +920,18 @@ key will be automatically imported without user confirmation.
Same as the [main] \fBexclude\fR option but only for this repository.
Substitution variables, described below, are honored here.
@@ -3646,7 +3676,7 @@ index 515aa73..eccfa38 100644
.IP
\fBenablegroups\fR
-@@ -755,6 +977,16 @@ repository.
+@@ -755,6 +979,16 @@ repository.
Overrides the \fBbandwidth\fR option from the [main] section for this
repository.
@@ -3663,7 +3693,7 @@ index 515aa73..eccfa38 100644
.IP
\fBsslcacert \fR
-@@ -776,6 +1008,10 @@ repository.
+@@ -776,6 +1010,10 @@ repository.
Overrides the \fBsslclientkey\fR option from the [main] section for this
repository.
@@ -3674,7 +3704,7 @@ index 515aa73..eccfa38 100644
.IP
\fBmetadata_expire \fR
-@@ -783,6 +1019,11 @@ Overrides the \fBmetadata_expire\fR option from the [main] section for this
+@@ -783,6 +1021,11 @@ Overrides the \fBmetadata_expire\fR option from the [main] section for this
repository.
.IP
@@ -3686,7 +3716,7 @@ index 515aa73..eccfa38 100644
\fBmirrorlist_expire \fR
Overrides the \fBmirrorlist_expire\fR option from the [main] section for this
repository.
-@@ -824,7 +1065,16 @@ as greater/less than any other. defaults to 1000
+@@ -824,7 +1067,16 @@ as greater/less than any other. defaults to 1000
If set to True yum will continue running if this repository cannot be
contacted for any reason. This should be set carefully as all repos are consulted
for any given command. Defaults to False.
@@ -186261,7 +186291,7 @@ index c1af4ad..70de539 100644
pass
diff --git a/yum/__init__.py b/yum/__init__.py
-index 99039e0..a4b14c0 100644
+index 99039e0..08792f4 100644
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -21,6 +21,7 @@ The Yum RPM software updater.
@@ -187451,7 +187481,7 @@ index 99039e0..a4b14c0 100644
errors = {}
def adderror(po, msg):
errors.setdefault(po, []).append(msg)
-@@ -1943,116 +2259,199 @@ class YumBase(depsolve.Depsolve):
+@@ -1943,116 +2259,200 @@ class YumBase(depsolve.Depsolve):
self.history.close()
self.plugins.run('predownload', pkglist=pkglist)
@@ -187480,6 +187510,7 @@ index 99039e0..a4b14c0 100644
+ po.localpath += '.%d.tmp' % os.getpid()
+ try: os.rename(local, po.localpath)
+ except OSError: pass
++ po.returnIdSum()
+ po.basepath # prefetch now; fails when repos are closed
+ return False
+
@@ -187740,7 +187771,7 @@ index 99039e0..a4b14c0 100644
if type(fo) is types.InstanceType:
fo = fo.filename
-@@ -2076,9 +2475,12 @@ class YumBase(depsolve.Depsolve):
+@@ -2076,9 +2476,12 @@ class YumBase(depsolve.Depsolve):
return 1
def downloadHeader(self, po):
@@ -187755,7 +187786,7 @@ index 99039e0..a4b14c0 100644
if hasattr(po, 'pkgtype') and po.pkgtype == 'local':
return
-@@ -2122,15 +2524,17 @@ class YumBase(depsolve.Depsolve):
+@@ -2122,15 +2525,17 @@ class YumBase(depsolve.Depsolve):
return
def sigCheckPkg(self, po):
@@ -187781,7 +187812,7 @@ index 99039e0..a4b14c0 100644
if self._override_sigchecks:
check = False
hasgpgkey = 0
-@@ -2181,6 +2585,9 @@ class YumBase(depsolve.Depsolve):
+@@ -2181,6 +2586,9 @@ class YumBase(depsolve.Depsolve):
return result, msg
def cleanUsedHeadersPackages(self):
@@ -187791,7 +187822,7 @@ index 99039e0..a4b14c0 100644
filelist = []
for txmbr in self.tsInfo:
if txmbr.po.state not in TS_INSTALL_STATES:
-@@ -2218,27 +2625,42 @@ class YumBase(depsolve.Depsolve):
+@@ -2218,27 +2626,42 @@ class YumBase(depsolve.Depsolve):
_('%s removed'), fn)
def cleanHeaders(self):
@@ -187836,7 +187867,7 @@ index 99039e0..a4b14c0 100644
cachedir = self.conf.persistdir + "/rpmdb-indexes/"
if not os.path.exists(cachedir):
filelist = []
-@@ -2271,9 +2693,31 @@ class YumBase(depsolve.Depsolve):
+@@ -2271,9 +2694,31 @@ class YumBase(depsolve.Depsolve):
return 0, [msg]
def doPackageLists(self, pkgnarrow='all', patterns=None, showdups=None,
@@ -187871,7 +187902,7 @@ index 99039e0..a4b14c0 100644
if showdups is None:
showdups = self.conf.showdupesfromrepos
ygh = misc.GenericHolder(iter=pkgnarrow)
-@@ -2295,6 +2739,8 @@ class YumBase(depsolve.Depsolve):
+@@ -2295,6 +2740,8 @@ class YumBase(depsolve.Depsolve):
ndinst = {} # Newest versions by name.arch
for po in self.rpmdb.returnPackages(patterns=patterns,
ignore_case=ic):
@@ -187880,7 +187911,7 @@ index 99039e0..a4b14c0 100644
dinst[po.pkgtup] = po
if showdups:
continue
-@@ -2304,8 +2750,13 @@ class YumBase(depsolve.Depsolve):
+@@ -2304,8 +2751,13 @@ class YumBase(depsolve.Depsolve):
installed = dinst.values()
if showdups:
@@ -187895,7 +187926,7 @@ index 99039e0..a4b14c0 100644
else:
try:
avail = self.pkgSack.returnNewestByNameArch(patterns=patterns,
-@@ -2323,16 +2774,30 @@ class YumBase(depsolve.Depsolve):
+@@ -2323,16 +2775,30 @@ class YumBase(depsolve.Depsolve):
key = (pkg.name, pkg.arch)
if pkg.pkgtup in dinst:
reinstall_available.append(pkg)
@@ -187929,7 +187960,7 @@ index 99039e0..a4b14c0 100644
if len(matches) > 1:
updates.append(matches[0])
self.verbose_logger.log(logginglevels.DEBUG_1,
-@@ -2352,13 +2817,19 @@ class YumBase(depsolve.Depsolve):
+@@ -2352,13 +2818,19 @@ class YumBase(depsolve.Depsolve):
elif pkgnarrow == 'installed':
installed = self.rpmdb.returnPackages(patterns=patterns,
ignore_case=ic)
@@ -187950,7 +187981,7 @@ index 99039e0..a4b14c0 100644
else:
try:
avail = self.pkgSack.returnNewestByNameArch(patterns=patterns,
-@@ -2392,9 +2863,21 @@ class YumBase(depsolve.Depsolve):
+@@ -2392,9 +2864,21 @@ class YumBase(depsolve.Depsolve):
avail = set(avail)
for po in self.rpmdb.returnPackages(patterns=patterns,
ignore_case=ic):
@@ -187972,7 +188003,7 @@ index 99039e0..a4b14c0 100644
# obsoleting packages (and what they obsolete)
elif pkgnarrow == 'obsoletes':
self.conf.obsoletes = 1
-@@ -2402,6 +2885,7 @@ class YumBase(depsolve.Depsolve):
+@@ -2402,6 +2886,7 @@ class YumBase(depsolve.Depsolve):
for (pkgtup, instTup) in self.up.getObsoletesTuples():
(n,a,e,v,r) = pkgtup
pkgs = self.pkgSack.searchNevra(name=n, arch=a, ver=v, rel=r, epoch=e)
@@ -187980,7 +188011,7 @@ index 99039e0..a4b14c0 100644
instpo = self.getInstalledPackageObject(instTup)
for po in pkgs:
obsoletes.append(po)
-@@ -2433,7 +2917,12 @@ class YumBase(depsolve.Depsolve):
+@@ -2433,7 +2918,12 @@ class YumBase(depsolve.Depsolve):
recentlimit = now-(self.conf.recent*86400)
if showdups:
avail = self.pkgSack.returnPackages(patterns=patterns,
@@ -187994,7 +188025,7 @@ index 99039e0..a4b14c0 100644
else:
try:
avail = self.pkgSack.returnNewestByNameArch(patterns=patterns,
-@@ -2461,14 +2950,13 @@ class YumBase(depsolve.Depsolve):
+@@ -2461,14 +2951,13 @@ class YumBase(depsolve.Depsolve):
def findDeps(self, pkgs):
@@ -188014,7 +188045,7 @@ index 99039e0..a4b14c0 100644
results = {}
for pkg in pkgs:
-@@ -2495,10 +2983,22 @@ class YumBase(depsolve.Depsolve):
+@@ -2495,10 +2984,22 @@ class YumBase(depsolve.Depsolve):
# pre 3.2.10 API used to always showdups, so that's the default atm.
def searchGenerator(self, fields, criteria, showdups=True, keys=False,
searchtags=True, searchrpmdb=True):
@@ -188041,7 +188072,7 @@ index 99039e0..a4b14c0 100644
sql_fields = []
for f in fields:
sql_fields.append(RPM_TO_SQLITE.get(f, f))
-@@ -2614,7 +3114,7 @@ class YumBase(depsolve.Depsolve):
+@@ -2614,7 +3115,7 @@ class YumBase(depsolve.Depsolve):
# ...but without showdups we want to output _just_ #3, which requires
# we find the newest EVR po for the best "matching value". Without keys
# it's the same, except we just want the newest EVR.
@@ -188050,7 +188081,7 @@ index 99039e0..a4b14c0 100644
# either, so it's pretty thankless. HTH. HAND.
# By default just sort using package sorting
sort_func = operator.itemgetter(0)
-@@ -2661,6 +3161,14 @@ class YumBase(depsolve.Depsolve):
+@@ -2661,6 +3162,14 @@ class YumBase(depsolve.Depsolve):
yield (po, vs)
def searchPackageTags(self, criteria):
@@ -188065,7 +188096,7 @@ index 99039e0..a4b14c0 100644
results = {} # name = [(criteria, taglist)]
for c in criteria:
c = c.lower()
-@@ -2677,11 +3185,16 @@ class YumBase(depsolve.Depsolve):
+@@ -2677,11 +3186,16 @@ class YumBase(depsolve.Depsolve):
return results
def searchPackages(self, fields, criteria, callback=None):
@@ -188087,7 +188118,7 @@ index 99039e0..a4b14c0 100644
warnings.warn(_('searchPackages() will go away in a future version of Yum.\
Use searchGenerator() instead. \n'),
Errors.YumFutureDeprecationWarning, stacklevel=2)
-@@ -2700,13 +3213,23 @@ class YumBase(depsolve.Depsolve):
+@@ -2700,13 +3214,23 @@ class YumBase(depsolve.Depsolve):
def searchPackageProvides(self, args, callback=None,
callback_has_matchfor=False):
@@ -188115,7 +188146,7 @@ index 99039e0..a4b14c0 100644
else:
isglob = True
canBeFile = misc.re_filename(arg)
-@@ -2723,7 +3246,7 @@ class YumBase(depsolve.Depsolve):
+@@ -2723,7 +3247,7 @@ class YumBase(depsolve.Depsolve):
where = self.returnPackagesByDep(arg)
else:
usedDepString = False
@@ -188124,7 +188155,7 @@ index 99039e0..a4b14c0 100644
self.verbose_logger.log(logginglevels.DEBUG_1,
P_('Searching %d package', 'Searching %d packages', len(where)), len(where))
-@@ -2817,25 +3340,168 @@ class YumBase(depsolve.Depsolve):
+@@ -2817,25 +3341,168 @@ class YumBase(depsolve.Depsolve):
return matches
@@ -188305,7 +188336,7 @@ index 99039e0..a4b14c0 100644
if uservisible:
if grp.user_visible:
installed.append(grp)
-@@ -2847,34 +3513,98 @@ class YumBase(depsolve.Depsolve):
+@@ -2847,34 +3514,98 @@ class YumBase(depsolve.Depsolve):
available.append(grp)
else:
available.append(grp)
@@ -188415,7 +188446,7 @@ index 99039e0..a4b14c0 100644
thesegroups = self.comps.return_groups(grpid)
if not thesegroups:
raise Errors.GroupsError, _("No Group named %s exists") % to_unicode(grpid)
-@@ -2898,13 +3628,58 @@ class YumBase(depsolve.Depsolve):
+@@ -2898,13 +3629,58 @@ class YumBase(depsolve.Depsolve):
self.tsInfo.remove(txmbr.po.pkgtup)
@@ -188481,7 +188512,7 @@ index 99039e0..a4b14c0 100644
"""
if not self.comps.has_group(grpid):
-@@ -2920,6 +3695,9 @@ class YumBase(depsolve.Depsolve):
+@@ -2920,6 +3696,9 @@ class YumBase(depsolve.Depsolve):
if group_package_types:
package_types = group_package_types
@@ -188491,7 +188522,7 @@ index 99039e0..a4b14c0 100644
for thisgroup in thesegroups:
if thisgroup.selected:
continue
-@@ -2934,12 +3712,51 @@ class YumBase(depsolve.Depsolve):
+@@ -2934,12 +3713,51 @@ class YumBase(depsolve.Depsolve):
if 'optional' in package_types:
pkgs.extend(thisgroup.optional_packages)
@@ -188544,7 +188575,7 @@ index 99039e0..a4b14c0 100644
except Errors.InstallError, e:
self.verbose_logger.debug(_('No package named %s available to be installed'),
pkg)
-@@ -2953,7 +3770,9 @@ class YumBase(depsolve.Depsolve):
+@@ -2953,7 +3771,9 @@ class YumBase(depsolve.Depsolve):
group_conditionals = enable_group_conditionals
count_cond_test = 0
@@ -188555,7 +188586,7 @@ index 99039e0..a4b14c0 100644
for condreq, cond in thisgroup.conditional_packages.iteritems():
if self.isPackageInstalled(cond):
try:
-@@ -2990,17 +3809,23 @@ class YumBase(depsolve.Depsolve):
+@@ -2990,17 +3810,23 @@ class YumBase(depsolve.Depsolve):
if cond not in self.tsInfo.conditionals:
self.tsInfo.conditionals[cond] = []
self.tsInfo.conditionals[cond].extend(pkgs)
@@ -188586,7 +188617,7 @@ index 99039e0..a4b14c0 100644
if not self.comps.has_group(grpid):
raise Errors.GroupsError, _("No Group named %s exists") % to_unicode(grpid)
-@@ -3008,7 +3833,8 @@ class YumBase(depsolve.Depsolve):
+@@ -3008,7 +3834,8 @@ class YumBase(depsolve.Depsolve):
thesegroups = self.comps.return_groups(grpid)
if not thesegroups:
raise Errors.GroupsError, _("No Group named %s exists") % to_unicode(grpid)
@@ -188596,7 +188627,7 @@ index 99039e0..a4b14c0 100644
for thisgroup in thesegroups:
thisgroup.selected = False
-@@ -3034,13 +3860,102 @@ class YumBase(depsolve.Depsolve):
+@@ -3034,13 +3861,102 @@ class YumBase(depsolve.Depsolve):
for pkg in self.tsInfo.conditionals.get(txmbr.name, []):
self.tsInfo.remove(pkg.pkgtup)
@@ -188705,7 +188736,7 @@ index 99039e0..a4b14c0 100644
# look it up in the self.localPackages first:
for po in self.localPackages:
if po.pkgtup == pkgtup:
-@@ -3049,7 +3964,7 @@ class YumBase(depsolve.Depsolve):
+@@ -3049,7 +3965,7 @@ class YumBase(depsolve.Depsolve):
pkgs = self.pkgSack.searchPkgTuple(pkgtup)
if len(pkgs) == 0:
@@ -188714,7 +188745,7 @@ index 99039e0..a4b14c0 100644
if allow_missing: # This can happen due to excludes after .up has
return None # happened.
raise Errors.DepError, _('Package tuple %s could not be found in packagesack') % str(pkgtup)
-@@ -3065,13 +3980,21 @@ class YumBase(depsolve.Depsolve):
+@@ -3065,13 +3981,21 @@ class YumBase(depsolve.Depsolve):
return result
def getInstalledPackageObject(self, pkgtup):
@@ -188741,7 +188772,7 @@ index 99039e0..a4b14c0 100644
raise Errors.RpmDBError, _('Package tuple %s could not be found in rpmdb') % str(pkgtup)
# Dito. FIXME from getPackageObject() for len() > 1 ... :)
-@@ -3079,9 +4002,11 @@ class YumBase(depsolve.Depsolve):
+@@ -3079,9 +4003,11 @@ class YumBase(depsolve.Depsolve):
return po
def gpgKeyCheck(self):
@@ -188755,7 +188786,7 @@ index 99039e0..a4b14c0 100644
gpgkeyschecked = self.conf.cachedir + '/.gpgkeyschecked.yum'
if os.path.exists(gpgkeyschecked):
return 1
-@@ -3106,9 +4031,13 @@ class YumBase(depsolve.Depsolve):
+@@ -3106,9 +4032,13 @@ class YumBase(depsolve.Depsolve):
return 1
def returnPackagesByDep(self, depstring):
@@ -188771,7 +188802,7 @@ index 99039e0..a4b14c0 100644
if not depstring:
return []
-@@ -3132,12 +4061,23 @@ class YumBase(depsolve.Depsolve):
+@@ -3132,12 +4062,23 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumBaseError, _('Invalid version flag from: %s') % str(depstring)
depflags = SYMBOLFLAGS[flagsymbol]
@@ -188798,7 +188829,7 @@ index 99039e0..a4b14c0 100644
# we get all sorts of randomness here
errstring = depstring
if type(depstring) not in types.StringTypes:
-@@ -3149,16 +4089,22 @@ class YumBase(depsolve.Depsolve):
+@@ -3149,16 +4090,22 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumBaseError, _('No Package found for %s') % errstring
ps = ListPackageSack(pkglist)
@@ -188825,7 +188856,7 @@ index 99039e0..a4b14c0 100644
if not depstring:
return []
-@@ -3182,14 +4128,53 @@ class YumBase(depsolve.Depsolve):
+@@ -3182,14 +4129,53 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumBaseError, _('Invalid version flag from: %s') % str(depstring)
depflags = SYMBOLFLAGS[flagsymbol]
@@ -188881,7 +188912,7 @@ index 99039e0..a4b14c0 100644
if len(pkglist) == 0:
-@@ -3198,14 +4183,23 @@ class YumBase(depsolve.Depsolve):
+@@ -3198,14 +4184,23 @@ class YumBase(depsolve.Depsolve):
if len(pkglist) == 1:
return pkglist[0]
@@ -188911,7 +188942,7 @@ index 99039e0..a4b14c0 100644
returnlist = []
compatArchList = self.arch.get_arch_list(arch)
multiLib = []
-@@ -3222,9 +4216,9 @@ class YumBase(depsolve.Depsolve):
+@@ -3222,9 +4217,9 @@ class YumBase(depsolve.Depsolve):
singleLib.append(po)
# we now have three lists. find the best package(s) of each
@@ -188924,7 +188955,7 @@ index 99039e0..a4b14c0 100644
if single_name and multi and single and multi.name != single.name:
# Sinlge _must_ match multi, if we want a single package name
-@@ -3238,7 +4232,7 @@ class YumBase(depsolve.Depsolve):
+@@ -3238,7 +4233,7 @@ class YumBase(depsolve.Depsolve):
# if there's a noarch and it's newer than the multilib, we want
# just the noarch. otherwise, we want multi + single
elif multi:
@@ -188933,7 +188964,7 @@ index 99039e0..a4b14c0 100644
if best.arch == "noarch":
returnlist.append(no)
else:
-@@ -3246,7 +4240,7 @@ class YumBase(depsolve.Depsolve):
+@@ -3246,7 +4241,7 @@ class YumBase(depsolve.Depsolve):
if single: returnlist.append(single)
# similar for the non-multilib case
elif single:
@@ -188942,7 +188973,7 @@ index 99039e0..a4b14c0 100644
if best.arch == "noarch":
returnlist.append(no)
else:
-@@ -3350,28 +4344,58 @@ class YumBase(depsolve.Depsolve):
+@@ -3350,28 +4345,58 @@ class YumBase(depsolve.Depsolve):
done = True
slow = next_func(slow)
@@ -189006,7 +189037,7 @@ index 99039e0..a4b14c0 100644
try:
txmbrs = self.groupRemove(group_string)
except yum.Errors.GroupsError:
-@@ -3387,6 +4411,8 @@ class YumBase(depsolve.Depsolve):
+@@ -3387,6 +4412,8 @@ class YumBase(depsolve.Depsolve):
assert pattern[0] == '@'
grpid = pattern[1:]
@@ -189015,7 +189046,7 @@ index 99039e0..a4b14c0 100644
thesegroups = self.comps.return_groups(grpid)
if not thesegroups:
raise Errors.GroupsError, _("No Group named %s exists") % to_unicode(grpid)
-@@ -3398,7 +4424,11 @@ class YumBase(depsolve.Depsolve):
+@@ -3398,7 +4425,11 @@ class YumBase(depsolve.Depsolve):
def _minus_deselect(self, pattern):
""" Remove things from the transaction, like kickstart. """
assert pattern[0] == '-'
@@ -189028,7 +189059,7 @@ index 99039e0..a4b14c0 100644
if pat and pat[0] == '@':
pat = pat[1:]
-@@ -3437,14 +4467,87 @@ class YumBase(depsolve.Depsolve):
+@@ -3437,14 +4468,87 @@ class YumBase(depsolve.Depsolve):
if flag not in self.tsInfo.probFilterFlags:
self.tsInfo.probFilterFlags.append(flag)
@@ -189122,7 +189153,7 @@ index 99039e0..a4b14c0 100644
pkgs = []
was_pattern = False
if po:
-@@ -3464,9 +4567,14 @@ class YumBase(depsolve.Depsolve):
+@@ -3464,9 +4568,14 @@ class YumBase(depsolve.Depsolve):
if kwargs['pattern'] and kwargs['pattern'][0] == '@':
return self._at_groupinstall(kwargs['pattern'])
@@ -189137,7 +189168,7 @@ index 99039e0..a4b14c0 100644
ignore_case=False)
pkgs.extend(mypkgs)
# if we have anything left unmatched, let's take a look for it
-@@ -3477,20 +4585,12 @@ class YumBase(depsolve.Depsolve):
+@@ -3477,20 +4586,12 @@ class YumBase(depsolve.Depsolve):
self.verbose_logger.debug(_('Checking for virtual provide or file-provide for %s'),
arg)
@@ -189164,7 +189195,7 @@ index 99039e0..a4b14c0 100644
else:
nevra_dict = self._nevra_kwarg_parse(kwargs)
-@@ -3499,6 +4599,8 @@ class YumBase(depsolve.Depsolve):
+@@ -3499,6 +4600,8 @@ class YumBase(depsolve.Depsolve):
ver=nevra_dict['version'], rel=nevra_dict['release'])
self._add_not_found_a(pkgs, nevra_dict)
@@ -189173,7 +189204,7 @@ index 99039e0..a4b14c0 100644
if pkgs:
# if was_pattern or nevra-dict['arch'] is none, take the list
# of arches based on our multilib_compat config and
-@@ -3577,17 +4679,21 @@ class YumBase(depsolve.Depsolve):
+@@ -3577,17 +4680,21 @@ class YumBase(depsolve.Depsolve):
continue
# make sure this shouldn't be passed to update:
@@ -189199,7 +189230,7 @@ index 99039e0..a4b14c0 100644
obsoleting_pkg = self._test_loop(po, self._pkg2obspkg)
if obsoleting_pkg is not None:
# this is not a definitive check but it'll make sure we don't
-@@ -3600,23 +4706,23 @@ class YumBase(depsolve.Depsolve):
+@@ -3600,23 +4707,23 @@ class YumBase(depsolve.Depsolve):
already_obs = pkgs[0]
if already_obs:
@@ -189230,7 +189261,7 @@ index 99039e0..a4b14c0 100644
continue
# make sure we don't have a name.arch of this already installed
-@@ -3630,8 +4736,8 @@ class YumBase(depsolve.Depsolve):
+@@ -3630,8 +4737,8 @@ class YumBase(depsolve.Depsolve):
found = True
break
if not found:
@@ -189241,7 +189272,7 @@ index 99039e0..a4b14c0 100644
tx_return.extend(txmbrs)
continue
-@@ -3719,19 +4825,47 @@ class YumBase(depsolve.Depsolve):
+@@ -3719,19 +4826,47 @@ class YumBase(depsolve.Depsolve):
return txmbr
def update(self, po=None, requiringPo=None, update_to=False, **kwargs):
@@ -189296,7 +189327,7 @@ index 99039e0..a4b14c0 100644
tx_return = []
if not po and not kwargs: # update everything (the easy case)
self.verbose_logger.log(logginglevels.DEBUG_2, _('Updating Everything'))
-@@ -3765,7 +4899,14 @@ class YumBase(depsolve.Depsolve):
+@@ -3765,7 +4900,14 @@ class YumBase(depsolve.Depsolve):
if new is None:
continue
tx_return.extend(self.update(po=new))
@@ -189312,7 +189343,7 @@ index 99039e0..a4b14c0 100644
return tx_return
# complications
-@@ -3787,13 +4928,16 @@ class YumBase(depsolve.Depsolve):
+@@ -3787,13 +4929,16 @@ class YumBase(depsolve.Depsolve):
return self._minus_deselect(kwargs['pattern'])
if kwargs['pattern'] and kwargs['pattern'][0] == '@':
@@ -189331,7 +189362,7 @@ index 99039e0..a4b14c0 100644
if not instpkgs and not availpkgs:
depmatches = []
-@@ -3805,6 +4949,8 @@ class YumBase(depsolve.Depsolve):
+@@ -3805,6 +4950,8 @@ class YumBase(depsolve.Depsolve):
except yum.Errors.YumBaseError, e:
self.logger.critical(_('%s') % e)
@@ -189340,7 +189371,7 @@ index 99039e0..a4b14c0 100644
if update_to:
availpkgs.extend(depmatches)
else:
-@@ -3816,9 +4962,12 @@ class YumBase(depsolve.Depsolve):
+@@ -3816,9 +4963,12 @@ class YumBase(depsolve.Depsolve):
try:
if update_to:
m = []
@@ -189354,7 +189385,7 @@ index 99039e0..a4b14c0 100644
m = self.pkgSack.returnNewestByNameArch(patterns=pats)
except Errors.PackageSackError:
m = []
-@@ -3843,7 +4992,7 @@ class YumBase(depsolve.Depsolve):
+@@ -3843,7 +4993,7 @@ class YumBase(depsolve.Depsolve):
availpkgs = self._compare_providers(availpkgs, requiringPo)
availpkgs = map(lambda x: x[0], availpkgs)
elif not availpkgs:
@@ -189363,7 +189394,7 @@ index 99039e0..a4b14c0 100644
# for any thing specified
# get the list of available pkgs matching it (or take the po)
-@@ -3879,6 +5028,7 @@ class YumBase(depsolve.Depsolve):
+@@ -3879,6 +5029,7 @@ class YumBase(depsolve.Depsolve):
if obsoleting_pkg is None:
continue
obs_pkgs.append(obsoleting_pkg)
@@ -189371,7 +189402,7 @@ index 99039e0..a4b14c0 100644
for obsoleting_pkg in packagesNewestByName(obs_pkgs):
tx_return.extend(self.install(po=obsoleting_pkg))
for available_pkg in availpkgs:
-@@ -3920,11 +5070,29 @@ class YumBase(depsolve.Depsolve):
+@@ -3920,11 +5071,29 @@ class YumBase(depsolve.Depsolve):
tx_return.append(txmbr)
for available_pkg in availpkgs:
@@ -189401,7 +189432,7 @@ index 99039e0..a4b14c0 100644
self.verbose_logger.log(logginglevels.DEBUG_2, _('Not Updating Package that is obsoleted: %s'), available_pkg)
tx_return.extend(self.update(po=obsoleting_pkg))
continue
-@@ -3985,11 +5153,18 @@ class YumBase(depsolve.Depsolve):
+@@ -3985,11 +5154,18 @@ class YumBase(depsolve.Depsolve):
return tx_return
def remove(self, po=None, **kwargs):
@@ -189425,7 +189456,7 @@ index 99039e0..a4b14c0 100644
if not po and not kwargs:
raise Errors.RemoveError, 'Nothing specified to remove'
-@@ -4008,6 +5183,10 @@ class YumBase(depsolve.Depsolve):
+@@ -4008,6 +5184,10 @@ class YumBase(depsolve.Depsolve):
return self._at_groupremove(kwargs['pattern'])
(e,m,u) = self.rpmdb.matchPackageNames([kwargs['pattern']])
@@ -189436,7 +189467,7 @@ index 99039e0..a4b14c0 100644
pkgs.extend(e)
pkgs.extend(m)
if u:
-@@ -4018,6 +5197,10 @@ class YumBase(depsolve.Depsolve):
+@@ -4018,6 +5198,10 @@ class YumBase(depsolve.Depsolve):
except yum.Errors.YumBaseError, e:
self.logger.critical(_('%s') % e)
@@ -189447,7 +189478,7 @@ index 99039e0..a4b14c0 100644
if not depmatches:
arg = to_unicode(arg)
self.logger.critical(_('No Match for argument: %s') % to_unicode(arg))
-@@ -4055,17 +5238,19 @@ class YumBase(depsolve.Depsolve):
+@@ -4055,17 +5239,19 @@ class YumBase(depsolve.Depsolve):
return tx_return
def installLocal(self, pkg, po=None, updateonly=False):
@@ -189477,7 +189508,7 @@ index 99039e0..a4b14c0 100644
# read in the package into a YumLocalPackage Object
# append it to self.localPackages
# check if it can be installed or updated based on nevra versus rpmdb
-@@ -4183,16 +5368,15 @@ class YumBase(depsolve.Depsolve):
+@@ -4183,16 +5369,15 @@ class YumBase(depsolve.Depsolve):
return tx_return
def reinstallLocal(self, pkg, po=None):
@@ -189502,7 +189533,7 @@ index 99039e0..a4b14c0 100644
if not po:
try:
po = YumUrlPackage(self, ts=self.rpmdb.readOnlyTS(), url=pkg,
-@@ -4215,13 +5399,29 @@ class YumBase(depsolve.Depsolve):
+@@ -4215,13 +5400,29 @@ class YumBase(depsolve.Depsolve):
return self.reinstall(po=po)
def reinstall(self, po=None, **kwargs):
@@ -189535,7 +189566,7 @@ index 99039e0..a4b14c0 100644
tx_mbrs = []
if po: # The po, is the "available" po ... we want the installed po
tx_mbrs.extend(self.remove(pkgtup=po.pkgtup))
-@@ -4240,10 +5440,11 @@ class YumBase(depsolve.Depsolve):
+@@ -4240,10 +5441,11 @@ class YumBase(depsolve.Depsolve):
# pkgs that are obsolete.
old_conf_obs = self.conf.obsoletes
self.conf.obsoletes = False
@@ -189549,7 +189580,7 @@ index 99039e0..a4b14c0 100644
self.conf.obsoletes = old_conf_obs
if len(members) == 0:
self.tsInfo.remove(item.pkgtup)
-@@ -4259,16 +5460,15 @@ class YumBase(depsolve.Depsolve):
+@@ -4259,16 +5461,15 @@ class YumBase(depsolve.Depsolve):
return tx_mbrs
def downgradeLocal(self, pkg, po=None):
@@ -189574,7 +189605,7 @@ index 99039e0..a4b14c0 100644
if not po:
try:
po = YumUrlPackage(self, ts=self.rpmdb.readOnlyTS(), url=pkg,
-@@ -4309,13 +5509,19 @@ class YumBase(depsolve.Depsolve):
+@@ -4309,13 +5510,19 @@ class YumBase(depsolve.Depsolve):
return False
def downgrade(self, po=None, **kwargs):
@@ -189601,7 +189632,7 @@ index 99039e0..a4b14c0 100644
if not po and not kwargs:
raise Errors.DowngradeError, 'Nothing specified to downgrade'
-@@ -4397,6 +5603,10 @@ class YumBase(depsolve.Depsolve):
+@@ -4397,6 +5604,10 @@ class YumBase(depsolve.Depsolve):
# installed version. Indexed fromn the latest installed pkgtup.
downgrade_apkgs = {}
for pkg in sorted(apkgs):
@@ -189612,7 +189643,7 @@ index 99039e0..a4b14c0 100644
na = (pkg.name, pkg.arch)
# Here we allow downgrades from .i386 => .noarch, or .i586 => .i386
-@@ -4421,6 +5631,9 @@ class YumBase(depsolve.Depsolve):
+@@ -4421,6 +5632,9 @@ class YumBase(depsolve.Depsolve):
warned_nas.add(na)
continue
@@ -189622,7 +189653,7 @@ index 99039e0..a4b14c0 100644
if pkg.verGE(lipkg):
if na not in warned_nas:
msg = _('Only Upgrade available on package: %s') % pkg
-@@ -4457,7 +5670,7 @@ class YumBase(depsolve.Depsolve):
+@@ -4457,7 +5671,7 @@ class YumBase(depsolve.Depsolve):
if e and v and r:
evr = '%s:%s-%s' % (e, v, r)
elif v and r:
@@ -189631,7 +189662,7 @@ index 99039e0..a4b14c0 100644
elif e and v:
evr = '%s:%s' % (e, v)
elif v: # e and r etc. is just too weird to print
-@@ -4500,12 +5713,24 @@ class YumBase(depsolve.Depsolve):
+@@ -4500,12 +5714,24 @@ class YumBase(depsolve.Depsolve):
return returndict
@@ -189659,7 +189690,7 @@ index 99039e0..a4b14c0 100644
old_conf_obs = self.conf.obsoletes
self.conf.obsoletes = False
done = False
-@@ -4515,19 +5740,46 @@ class YumBase(depsolve.Depsolve):
+@@ -4515,19 +5741,46 @@ class YumBase(depsolve.Depsolve):
done = True
for pkg in transaction.trans_data:
if pkg.state == 'Downgrade':
@@ -189706,7 +189737,7 @@ index 99039e0..a4b14c0 100644
if self.install(pkgtup=pkg.pkgtup):
done = True
for pkg in transaction.trans_data:
-@@ -4538,8 +5790,14 @@ class YumBase(depsolve.Depsolve):
+@@ -4538,8 +5791,14 @@ class YumBase(depsolve.Depsolve):
return done
def history_undo(self, transaction):
@@ -189723,7 +189754,7 @@ index 99039e0..a4b14c0 100644
# NOTE: This is somewhat basic atm. ... for instance we don't check
# that we are going from the old new version. However it's still
# better than the RHN rollback code, and people pay for that :).
-@@ -4616,7 +5874,7 @@ class YumBase(depsolve.Depsolve):
+@@ -4616,7 +5875,7 @@ class YumBase(depsolve.Depsolve):
except urlgrabber.grabber.URLGrabError, e:
raise Errors.YumBaseError(_('GPG key retrieval failed: ') +
@@ -189732,7 +189763,7 @@ index 99039e0..a4b14c0 100644
# check for a .asc file accompanying it - that's our gpg sig on the key
# suck it down and do the check
-@@ -4649,7 +5907,7 @@ class YumBase(depsolve.Depsolve):
+@@ -4649,7 +5908,7 @@ class YumBase(depsolve.Depsolve):
keys_info = misc.getgpgkeyinfo(rawkey, multiple=True)
except ValueError, e:
raise Errors.YumBaseError(_('Invalid GPG Key from %s: %s') %
@@ -189741,7 +189772,7 @@ index 99039e0..a4b14c0 100644
keys = []
for keyinfo in keys_info:
thiskey = {}
-@@ -4674,39 +5932,49 @@ class YumBase(depsolve.Depsolve):
+@@ -4674,39 +5933,49 @@ class YumBase(depsolve.Depsolve):
if pkgs:
pkgs = sorted(pkgs)[-1]
msg = (_('Importing %s key 0x%s:\n'
@@ -189809,7 +189840,7 @@ index 99039e0..a4b14c0 100644
user_cb_fail = False
for keyurl in keyurls:
keys = self._retrievePublicKey(keyurl, repo)
-@@ -4725,7 +5993,9 @@ class YumBase(depsolve.Depsolve):
+@@ -4725,7 +5994,9 @@ class YumBase(depsolve.Depsolve):
# Try installing/updating GPG key
self._getKeyImportMessage(info, keyurl)
rc = False
@@ -189820,7 +189851,7 @@ index 99039e0..a4b14c0 100644
rc = True
# grab the .sig/.asc for the keyurl, if it exists
-@@ -4751,8 +6021,8 @@ class YumBase(depsolve.Depsolve):
+@@ -4751,8 +6022,8 @@ class YumBase(depsolve.Depsolve):
ts = self.rpmdb.readOnlyTS()
result = ts.pgpImportPubkey(misc.procgpgkey(info['raw_key']))
if result != 0:
@@ -189831,7 +189862,7 @@ index 99039e0..a4b14c0 100644
self.logger.info(_('Key imported successfully'))
key_installed = True
-@@ -4760,18 +6030,20 @@ class YumBase(depsolve.Depsolve):
+@@ -4760,18 +6031,20 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumBaseError, _("Didn't install any keys")
if not key_installed:
@@ -189857,7 +189888,7 @@ index 99039e0..a4b14c0 100644
def _getAnyKeyForRepo(self, repo, destdir, keyurl_list, is_cakey=False, callback=None):
"""
-@@ -4788,6 +6060,18 @@ class YumBase(depsolve.Depsolve):
+@@ -4788,6 +6061,18 @@ class YumBase(depsolve.Depsolve):
"""
key_installed = False
@@ -189876,7 +189907,7 @@ index 99039e0..a4b14c0 100644
user_cb_fail = False
for keyurl in keyurl_list:
keys = self._retrievePublicKey(keyurl, repo, getSig=not is_cakey)
-@@ -4819,8 +6103,11 @@ class YumBase(depsolve.Depsolve):
+@@ -4819,8 +6104,11 @@ class YumBase(depsolve.Depsolve):
if not key_installed:
self._getKeyImportMessage(info, keyurl, keytype)
rc = False
@@ -189889,7 +189920,7 @@ index 99039e0..a4b14c0 100644
elif callback:
rc = callback({"repo": repo, "userid": info['userid'],
"hexkeyid": info['hexkeyid'], "keyurl": keyurl,
-@@ -4835,7 +6122,8 @@ class YumBase(depsolve.Depsolve):
+@@ -4835,7 +6123,8 @@ class YumBase(depsolve.Depsolve):
# Import the key
result = misc.import_key_to_pubring(info['raw_key'], info['hexkeyid'], gpgdir=destdir)
if not result:
@@ -189899,7 +189930,7 @@ index 99039e0..a4b14c0 100644
self.logger.info(_('Key imported successfully'))
key_installed = True
# write out the key id to imported_cakeys in the repos basedir
-@@ -4851,36 +6139,35 @@ class YumBase(depsolve.Depsolve):
+@@ -4851,36 +6140,35 @@ class YumBase(depsolve.Depsolve):
pass
if not key_installed and user_cb_fail:
@@ -189952,7 +189983,7 @@ index 99039e0..a4b14c0 100644
self._getAnyKeyForRepo(repo, repo.gpgcadir, repo.gpgcakey, is_cakey=True, callback=callback)
def _limit_installonly_pkgs(self):
-@@ -4889,7 +6176,7 @@ class YumBase(depsolve.Depsolve):
+@@ -4889,7 +6177,7 @@ class YumBase(depsolve.Depsolve):
New in 3.2.24: Obey yumdb_info.installonly data. """
def _sort_and_filter_installonly(pkgs):
@@ -189961,7 +189992,7 @@ index 99039e0..a4b14c0 100644
using the yumdb. """
ret_beg = []
ret_mid = []
-@@ -4926,23 +6213,30 @@ class YumBase(depsolve.Depsolve):
+@@ -4926,23 +6214,30 @@ class YumBase(depsolve.Depsolve):
# so self.rpmdb.ts should be valid.
ts = self.rpmdb.readOnlyTS()
(cur_kernel_v, cur_kernel_r) = misc.get_running_kernel_version_release(ts)
@@ -190000,7 +190031,7 @@ index 99039e0..a4b14c0 100644
for po in installed:
if (po.version, po.release) == (cur_kernel_v, cur_kernel_r):
# don't remove running
-@@ -4959,19 +6253,22 @@ class YumBase(depsolve.Depsolve):
+@@ -4959,19 +6254,22 @@ class YumBase(depsolve.Depsolve):
txmbr.depends_on.append(rel)
def processTransaction(self, callback=None,rpmTestDisplay=None, rpmDisplay=None):
@@ -190036,7 +190067,7 @@ index 99039e0..a4b14c0 100644
if not callback:
callback = callbacks.ProcessTransNoOutputCallback()
-@@ -5062,8 +6359,8 @@ class YumBase(depsolve.Depsolve):
+@@ -5062,8 +6360,8 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumRPMCheckError, retmsgs
retmsgs = [_('ERROR with transaction check vs depsolve:')]
retmsgs.extend(msgs)
@@ -190047,7 +190078,7 @@ index 99039e0..a4b14c0 100644
raise Errors.YumRPMCheckError,retmsgs
tsConf = {}
-@@ -5114,13 +6411,19 @@ class YumBase(depsolve.Depsolve):
+@@ -5114,13 +6412,19 @@ class YumBase(depsolve.Depsolve):
return results
def add_enable_repo(self, repoid, baseurls=[], mirrorlist=None, **kwargs):
@@ -190074,7 +190105,7 @@ index 99039e0..a4b14c0 100644
# out of place fixme - maybe we should make this the default repo addition
# routine and use it from getReposFromConfigFile(), etc.
newrepo = yumRepo.YumRepository(repoid)
-@@ -5167,9 +6470,15 @@ class YumBase(depsolve.Depsolve):
+@@ -5167,9 +6471,15 @@ class YumBase(depsolve.Depsolve):
def setCacheDir(self, force=False, tmpdir=None, reuse=True,
suffix='/$basearch/$releasever'):
@@ -190093,7 +190124,7 @@ index 99039e0..a4b14c0 100644
if not force and os.geteuid() == 0:
return True # We are root, not forced, so happy with the global dir.
if tmpdir is None:
-@@ -5179,7 +6488,7 @@ class YumBase(depsolve.Depsolve):
+@@ -5179,7 +6489,7 @@ class YumBase(depsolve.Depsolve):
try:
cachedir = misc.getCacheDir(tmpdir, reuse)
except (IOError, OSError), e:
@@ -190102,7 +190133,7 @@ index 99039e0..a4b14c0 100644
cachedir = None
if cachedir is None:
-@@ -5190,6 +6499,8 @@ class YumBase(depsolve.Depsolve):
+@@ -5190,6 +6500,8 @@ class YumBase(depsolve.Depsolve):
self.prerepoconf.cachedir = cachedir
else:
self.repos.setCacheDir(cachedir)
@@ -190111,7 +190142,7 @@ index 99039e0..a4b14c0 100644
self.conf.cachedir = cachedir
return True # We got a new cache dir
-@@ -5220,13 +6531,24 @@ class YumBase(depsolve.Depsolve):
+@@ -5220,13 +6532,24 @@ class YumBase(depsolve.Depsolve):
self.history.write_addon_data('config-repos', myrepos)
def verify_plugins_cb(self, verify_package):
@@ -190139,7 +190170,7 @@ index 99039e0..a4b14c0 100644
if self.tsInfo._unresolvedMembers:
if auto:
self.logger.critical(_("Dependencies not solved. Will not save unresolved transaction."))
-@@ -5234,7 +6556,7 @@ class YumBase(depsolve.Depsolve):
+@@ -5234,7 +6557,7 @@ class YumBase(depsolve.Depsolve):
raise Errors.YumBaseError(_("Dependencies not solved. Will not save unresolved transaction."))
if not filename:
@@ -190148,7 +190179,7 @@ index 99039e0..a4b14c0 100644
fd,filename = tempfile.mkstemp(suffix='.yumtx', prefix=prefix)
f = os.fdopen(fd, 'w')
else:
-@@ -5244,13 +6566,17 @@ class YumBase(depsolve.Depsolve):
+@@ -5244,13 +6567,17 @@ class YumBase(depsolve.Depsolve):
msg = "%s\n" % self.rpmdb.simpleVersion(main_only=True)[0]
msg += "%s\n" % self.ts.getTsFlags()
@@ -190169,7 +190200,7 @@ index 99039e0..a4b14c0 100644
msg += "%s\n" % len(self.tsInfo.getMembers())
for txmbr in self.tsInfo.getMembers():
msg += txmbr._dump()
-@@ -5260,42 +6586,84 @@ class YumBase(depsolve.Depsolve):
+@@ -5260,42 +6587,84 @@ class YumBase(depsolve.Depsolve):
except (IOError, OSError), e:
self._ts_save_file = None
if auto:
@@ -190266,7 +190297,7 @@ index 99039e0..a4b14c0 100644
if ignorerpm:
msg += _(" ignoring, as requested.")
self.logger.critical(_(msg))
-@@ -5318,8 +6686,17 @@ class YumBase(depsolve.Depsolve):
+@@ -5318,8 +6687,17 @@ class YumBase(depsolve.Depsolve):
numrepos = int(data[2].strip())
repos = []
rindex=3+numrepos
@@ -190285,7 +190316,7 @@ index 99039e0..a4b14c0 100644
# pkgs/txmbrs
numpkgs = int(data[rindex].strip())
-@@ -5329,6 +6706,7 @@ class YumBase(depsolve.Depsolve):
+@@ -5329,6 +6707,7 @@ class YumBase(depsolve.Depsolve):
pkgcount = 0
pkgprob = False
curpkg = None
@@ -190293,7 +190324,7 @@ index 99039e0..a4b14c0 100644
for l in data[pkgstart:]:
l = l.rstrip()
# our main txmbrs
-@@ -5356,6 +6734,7 @@ class YumBase(depsolve.Depsolve):
+@@ -5356,6 +6735,7 @@ class YumBase(depsolve.Depsolve):
if not ignoremissing:
raise Errors.YumBaseError(msg)
else:
@@ -190301,7 +190332,7 @@ index 99039e0..a4b14c0 100644
self.logger.critical(msg)
else:
pkgcount += 1
-@@ -5432,12 +6811,18 @@ class YumBase(depsolve.Depsolve):
+@@ -5432,12 +6812,18 @@ class YumBase(depsolve.Depsolve):
if pkgprob:
msg = _("Transaction members, relations are missing or ts has been modified,")
if ignoremissing:
@@ -190320,7 +190351,7 @@ index 99039e0..a4b14c0 100644
return self.tsInfo.getMembers()
def _remove_old_deps(self):
-@@ -5470,18 +6855,6 @@ class YumBase(depsolve.Depsolve):
+@@ -5470,18 +6856,6 @@ class YumBase(depsolve.Depsolve):
if requiring == required: # if they are self-requiring skip them
continue
@@ -190339,7 +190370,7 @@ index 99039e0..a4b14c0 100644
#for tbi_pkg in self.tsInfo.getMembersWithState(output_states=TS_INSTALL_STATES):
# for reqtuple in tbi_pkg.po.requires:
# if required.provides_for(reqtuple):
-@@ -5533,7 +6906,24 @@ class YumBase(depsolve.Depsolve):
+@@ -5533,7 +6907,24 @@ class YumBase(depsolve.Depsolve):
# Debugging output
self.verbose_logger.log(logginglevels.DEBUG_2, _("%s has revdep %s which was user-installed."), pkg, curpkg)
ok_to_remove[pkg] = False
@@ -190364,7 +190395,7 @@ index 99039e0..a4b14c0 100644
visited[curpkg] = True
all_leaves_visited = True
leaves = curpkg.requiring_packages()
-@@ -5547,4 +6937,3 @@ class YumBase(depsolve.Depsolve):
+@@ -5547,4 +6938,3 @@ class YumBase(depsolve.Depsolve):
# Debugging output
self.verbose_logger.log(logginglevels.DEBUG_2, _("%s has no user-installed revdeps."), pkg)
return False
@@ -191015,7 +191046,7 @@ index 65f6d5e..af79a55 100755
print >> sys.stderr, "newcomps.py: No such file:\'%s\'" % sys.argv[1]
sys.exit(1)
diff --git a/yum/config.py b/yum/config.py
-index d09511f..967a4c8 100644
+index d09511f..1ca5cdc 100644
--- a/yum/config.py
+++ b/yum/config.py
@@ -45,15 +45,18 @@ from misc import get_uuid, read_in_items_from_dot_dir
@@ -191227,21 +191258,30 @@ index d09511f..967a4c8 100644
url = url.strip()
# Handle the "_none_" special case
-@@ -224,10 +238,9 @@ class UrlOption(Option):
+@@ -223,11 +237,18 @@ class UrlOption(Option):
+ else:
return '%s or %s' % (', '.join(self.schemes[:-1]), self.schemes[-1])
- class UrlListOption(ListOption):
+-class UrlListOption(ListOption):
- '''
- Option for handling lists of URLs with validation of the URL scheme.
- '''
--
++class ProxyOption(UrlOption):
++ """ Just like URLOption but accept "libproxy" too.
++ """
++ def parse(self, proxy):
++ if proxy.strip().lower() == 'libproxy':
++ return 'libproxy'
++ return UrlOption.parse(self, proxy)
+
++class UrlListOption(ListOption):
+ """Option for handling lists of URLs with validation of the URL
+ scheme.
+ """
def __init__(self, default=None, schemes=('http', 'ftp', 'file', 'https'),
parse_default=False):
super(UrlListOption, self).__init__(default, parse_default)
-@@ -236,6 +249,13 @@ class UrlListOption(ListOption):
+@@ -236,6 +257,13 @@ class UrlListOption(ListOption):
self._urloption = UrlOption(schemes=schemes)
def parse(self, s):
@@ -191255,7 +191295,7 @@ index d09511f..967a4c8 100644
out = []
s = s.replace('\n', ' ')
s = s.replace(',', ' ')
-@@ -254,10 +274,7 @@ class UrlListOption(ListOption):
+@@ -254,10 +282,7 @@ class UrlListOption(ListOption):
class IntOption(Option):
@@ -191267,7 +191307,7 @@ index d09511f..967a4c8 100644
def __init__(self, default=None, range_min=None, range_max=None):
super(IntOption, self).__init__(default)
-@@ -265,6 +282,13 @@ class IntOption(Option):
+@@ -265,6 +290,13 @@ class IntOption(Option):
self._range_max = range_max
def parse(self, s):
@@ -191281,17 +191321,17 @@ index d09511f..967a4c8 100644
try:
val = int(s)
except (ValueError, TypeError), e:
-@@ -276,39 +300,56 @@ class IntOption(Option):
+@@ -276,39 +308,56 @@ class IntOption(Option):
return val
class PositiveIntOption(IntOption):
-
-- """
-- An option representing a positive integer value, where 0 can have a special
-- represention.
+ """An option representing a positive integer value, where 0 can
+ have a special representation.
"""
+- An option representing a positive integer value, where 0 can have a special
+- represention.
+- """
-
def __init__(self, default=None, range_min=0, range_max=None,
names_of_0=None):
@@ -191352,7 +191392,7 @@ index d09511f..967a4c8 100644
if len(s) < 1:
raise ValueError("no value specified")
-@@ -335,14 +376,20 @@ class SecondsOption(Option):
+@@ -335,14 +384,20 @@ class SecondsOption(Option):
return int(n * mult)
class BoolOption(Option):
@@ -191378,7 +191418,7 @@ index d09511f..967a4c8 100644
s = s.lower()
if s in ('0', 'no', 'false'):
return False
-@@ -352,30 +399,49 @@ class BoolOption(Option):
+@@ -352,30 +407,49 @@ class BoolOption(Option):
raise ValueError('invalid boolean value')
def tostring(self, value):
@@ -191433,7 +191473,7 @@ index d09511f..967a4c8 100644
if s in self._mapper:
s = self._mapper[s]
if s not in self._allowed:
-@@ -383,18 +449,21 @@ class SelectionOption(Option):
+@@ -383,18 +457,21 @@ class SelectionOption(Option):
return s
class CaselessSelectionOption(SelectionOption):
@@ -191463,7 +191503,7 @@ index d09511f..967a4c8 100644
"""
# Multipliers for unit symbols
MULTS = {
-@@ -404,20 +473,18 @@ class BytesOption(Option):
+@@ -404,20 +481,18 @@ class BytesOption(Option):
}
def parse(self, s):
@@ -191480,11 +191520,11 @@ index d09511f..967a4c8 100644
- Valid inputs: 100, 123M, 45.6k, 12.4G, 100K, 786.3, 0
- Invalid inputs: -10, -0.1, 45.6L, 123Mb
--
-- Return value will always be an integer
+ Valid inputs: 100, 123M, 45.6k, 12.4G, 100K, 786.3, 0.
+ Invalid inputs: -10, -0.1, 45.6L, 123Mb.
+- Return value will always be an integer
+-
- 1k = 1024 bytes.
-
- ValueError will be raised if the option couldn't be parsed.
@@ -191494,7 +191534,7 @@ index d09511f..967a4c8 100644
"""
if len(s) < 1:
raise ValueError("no value specified")
-@@ -443,25 +510,23 @@ class BytesOption(Option):
+@@ -443,25 +518,23 @@ class BytesOption(Option):
return int(n * mult)
class ThrottleOption(BytesOption):
@@ -191534,7 +191574,7 @@ index d09511f..967a4c8 100644
"""
if len(s) < 1:
raise ValueError("no value specified")
-@@ -479,10 +544,9 @@ class ThrottleOption(BytesOption):
+@@ -479,10 +552,9 @@ class ThrottleOption(BytesOption):
return BytesOption.parse(self, s)
class BaseConfig(object):
@@ -191548,7 +191588,7 @@ index d09511f..967a4c8 100644
def __init__(self):
self._section = None
-@@ -499,13 +563,14 @@ class BaseConfig(object):
+@@ -499,13 +571,14 @@ class BaseConfig(object):
return '\n'.join(out)
def populate(self, parser, section, parent=None):
@@ -191569,7 +191609,7 @@ index d09511f..967a4c8 100644
self.cfg = parser
self._section = section
-@@ -527,8 +592,19 @@ class BaseConfig(object):
+@@ -527,8 +600,19 @@ class BaseConfig(object):
setattr(self, name, value)
def optionobj(cls, name, exceptions=True):
@@ -191591,7 +191631,7 @@ index d09511f..967a4c8 100644
obj = getattr(cls, name, None)
if isinstance(obj, Option):
return obj
-@@ -539,37 +615,41 @@ class BaseConfig(object):
+@@ -539,37 +623,41 @@ class BaseConfig(object):
optionobj = classmethod(optionobj)
def isoption(cls, name):
@@ -191648,7 +191688,7 @@ index d09511f..967a4c8 100644
# Write section heading
if section is None:
if self._section is None:
-@@ -586,6 +666,14 @@ class BaseConfig(object):
+@@ -586,6 +674,14 @@ class BaseConfig(object):
self.cfg.write(fileobj)
def getConfigOption(self, option, default=None):
@@ -191663,7 +191703,7 @@ index d09511f..967a4c8 100644
warnings.warn('getConfigOption() will go away in a future version of Yum.\n'
'Please access option values as attributes or using getattr().',
DeprecationWarning)
-@@ -594,6 +682,12 @@ class BaseConfig(object):
+@@ -594,6 +690,12 @@ class BaseConfig(object):
return default
def setConfigOption(self, option, value):
@@ -191676,7 +191716,7 @@ index d09511f..967a4c8 100644
warnings.warn('setConfigOption() will go away in a future version of Yum.\n'
'Please set option values as attributes or using setattr().',
DeprecationWarning)
-@@ -603,11 +697,10 @@ class BaseConfig(object):
+@@ -603,11 +705,10 @@ class BaseConfig(object):
raise Errors.ConfigError, 'No such option %s' % option
class StartupConf(BaseConfig):
@@ -191692,7 +191732,7 @@ index d09511f..967a4c8 100644
# xemacs highlighting hack: '
debuglevel = IntOption(2, 0, 10)
errorlevel = IntOption(2, 0, 10)
-@@ -625,13 +718,13 @@ class StartupConf(BaseConfig):
+@@ -625,13 +726,13 @@ class StartupConf(BaseConfig):
persistdir = Option('/var/lib/yum')
class YumConf(StartupConf):
@@ -191710,14 +191750,14 @@ index d09511f..967a4c8 100644
cachedir = Option('/var/cache/yum')
-@@ -641,20 +734,24 @@ class YumConf(StartupConf):
+@@ -641,20 +742,24 @@ class YumConf(StartupConf):
commands = ListOption()
exclude = ListOption()
- failovermethod = Option('roundrobin')
- proxy = UrlOption(schemes=('http', 'ftp', 'https'), allow_none=True)
+ failovermethod = Option(__main_failovermethod_default__)
-+ proxy = UrlOption(default=False, schemes=('http', 'ftp', 'https',
++ proxy = ProxyOption(default=False, schemes=('http', 'ftp', 'https',
+ 'socks4', 'socks4a', 'socks5', 'socks5h'), allow_none=True)
proxy_username = Option()
proxy_password = Option()
@@ -191738,7 +191778,7 @@ index d09511f..967a4c8 100644
names_of_0=["0", "<off>"])
kernelpkgnames = ListOption(['kernel','kernel-smp', 'kernel-enterprise',
'kernel-bigmem', 'kernel-BOOT', 'kernel-PAE', 'kernel-PAE-debug'])
-@@ -664,6 +761,7 @@ class YumConf(StartupConf):
+@@ -664,6 +769,7 @@ class YumConf(StartupConf):
tsflags = ListOption()
assumeyes = BoolOption(False)
@@ -191746,7 +191786,7 @@ index d09511f..967a4c8 100644
alwaysprompt = BoolOption(True)
exactarch = BoolOption(True)
tolerant = BoolOption(True)
-@@ -677,18 +775,33 @@ class YumConf(StartupConf):
+@@ -677,18 +783,33 @@ class YumConf(StartupConf):
obsoletes = BoolOption(True)
showdupesfromrepos = BoolOption(False)
enabled = BoolOption(True)
@@ -191780,7 +191820,7 @@ index d09511f..967a4c8 100644
# Time in seconds (1 day). NOTE: This isn't used when using metalinks
mirrorlist_expire = SecondsOption(60 * 60 * 24)
# XXX rpm_check_debug is unused, left around for API compatibility for now
-@@ -698,12 +811,14 @@ class YumConf(StartupConf):
+@@ -698,12 +819,14 @@ class YumConf(StartupConf):
# Note that "instant" is the old behaviour, but group:primary is very
# similar but better :).
mdpolicy = ListOption(['group:primary'])
@@ -191797,7 +191837,7 @@ index d09511f..967a4c8 100644
color = SelectionOption('auto', ('auto', 'never', 'always'),
mapper={'on' : 'always', 'yes' : 'always',
-@@ -715,22 +830,27 @@ class YumConf(StartupConf):
+@@ -715,22 +838,27 @@ class YumConf(StartupConf):
color_list_installed_newer = Option('bold,yellow')
color_list_installed_reinstall = Option('normal')
color_list_installed_extra = Option('bold,red')
@@ -191825,7 +191865,7 @@ index d09511f..967a4c8 100644
history_record = BoolOption(True)
history_record_packages = ListOption(['yum', 'rpm'])
-@@ -744,18 +864,29 @@ class YumConf(StartupConf):
+@@ -744,18 +872,29 @@ class YumConf(StartupConf):
loadts_ignoremissing = BoolOption(False)
loadts_ignorerpm = BoolOption(False)
@@ -191855,7 +191895,7 @@ index d09511f..967a4c8 100644
output = '[main]\n'
# we exclude all vars which start with _ or are in this list:
excluded_vars = ('cfg', 'uid', 'yumvar', 'progress_obj', 'failure_obj',
-@@ -778,14 +909,12 @@ class YumConf(StartupConf):
+@@ -778,14 +917,12 @@ class YumConf(StartupConf):
return output
class RepoConf(BaseConfig):
@@ -191873,7 +191913,7 @@ index d09511f..967a4c8 100644
ck = self.__cached_keys
if not isinstance(self, RepoConf):
ck = set()
-@@ -820,42 +949,52 @@ class RepoConf(BaseConfig):
+@@ -820,42 +957,52 @@ class RepoConf(BaseConfig):
keepalive = Inherit(YumConf.keepalive)
enablegroups = Inherit(YumConf.enablegroups)
@@ -191937,7 +191977,7 @@ index d09511f..967a4c8 100644
# ' xemacs syntax hack
-@@ -876,20 +1015,24 @@ def readStartupConfig(configfile, root):
+@@ -876,20 +1023,24 @@ def readStartupConfig(configfile, root):
raise Errors.ConfigError("All plugin search paths must be absolute")
# Stuff this here to avoid later re-parsing
startupconf._parser = parser
@@ -191968,7 +192008,7 @@ index d09511f..967a4c8 100644
# ' xemacs syntax hack
-@@ -956,6 +1099,12 @@ def readMainConfig(startupconf):
+@@ -956,6 +1107,12 @@ def readMainConfig(startupconf):
return yumconf
def readVersionGroupsConfig(configfile="/etc/yum/version-groups.conf"):
@@ -191981,7 +192021,7 @@ index d09511f..967a4c8 100644
parser = ConfigParser()
confpp_obj = ConfigPreProcessor(configfile)
try:
-@@ -970,17 +1119,16 @@ def readVersionGroupsConfig(configfile="/etc/yum/version-groups.conf"):
+@@ -970,17 +1127,16 @@ def readVersionGroupsConfig(configfile="/etc/yum/version-groups.conf"):
def getOption(conf, section, name, option):
@@ -192009,7 +192049,7 @@ index d09511f..967a4c8 100644
try:
val = conf.get(section, name)
except (NoSectionError, NoOptionError):
-@@ -1028,25 +1176,28 @@ def _getsysver(installroot, distroverpkg):
+@@ -1028,25 +1184,28 @@ def _getsysver(installroot, distroverpkg):
if idx.count() == 0:
releasever = '$releasever'
else:
@@ -192049,7 +192089,7 @@ index d09511f..967a4c8 100644
# b/c repoids can have $values in them we need to map both ways to figure
# out which one is which
section_id = repo.id
-@@ -1054,6 +1205,19 @@ def writeRawRepoFile(repo,only=None):
+@@ -1054,6 +1213,19 @@ def writeRawRepoFile(repo,only=None):
for sect in ini._sections.keys():
if varReplace(sect, repo.yumvar) == repo.id:
section_id = sect
@@ -192069,7 +192109,7 @@ index d09511f..967a4c8 100644
# Updated the ConfigParser with the changed values
cfgOptions = repo.cfg.options(repo.id)
-@@ -1069,7 +1233,7 @@ def writeRawRepoFile(repo,only=None):
+@@ -1069,7 +1241,7 @@ def writeRawRepoFile(repo,only=None):
# If the value is the same, but just interpreted ... when we don't want
# to keep the interpreted values.
if (name in ini[section_id] and
@@ -197078,7 +197118,7 @@ index 0000000..1cc207f
+ return txmbrs
+
diff --git a/yum/yumRepo.py b/yum/yumRepo.py
-index e5e9ece..ef6d9c6 100644
+index e5e9ece..cfe7b05 100644
--- a/yum/yumRepo.py
+++ b/yum/yumRepo.py
@@ -20,10 +20,12 @@ import time
@@ -197431,7 +197471,7 @@ index e5e9ece..ef6d9c6 100644
if proxy_string is not None:
self._proxy_dict['http'] = proxy_string
-@@ -483,14 +605,50 @@ class YumRepository(Repository, config.RepoConf):
+@@ -483,22 +605,59 @@ class YumRepository(Repository, config.RepoConf):
ugopts = self._default_grabopts()
self._grabfunc = URLGrabber(progress_obj=self.callback,
@@ -197484,16 +197524,28 @@ index e5e9ece..ef6d9c6 100644
def _default_grabopts(self, cache=True):
opts = { 'keepalive': self.keepalive,
-@@ -499,6 +657,8 @@ class YumRepository(Repository, config.RepoConf):
+ 'bandwidth': self.bandwidth,
+ 'retry': self.retries,
'throttle': self.throttle,
- 'proxies': self.proxy_dict,
+- 'proxies': self.proxy_dict,
'timeout': self.timeout,
+ 'minrate': self.minrate,
+ 'ip_resolve': self.ip_resolve,
'http_headers': tuple(self.__headersListFromDict(cache=cache)),
'ssl_verify_peer': self.sslverify,
'ssl_verify_host': self.sslverify,
-@@ -561,7 +721,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -509,6 +668,10 @@ class YumRepository(Repository, config.RepoConf):
+ 'username': self.username,
+ 'password': self.password,
+ }
++ if self.proxy == 'libproxy':
++ opts['libproxy'] = True
++ else:
++ opts['proxies'] = self.proxy_dict
+ return opts
+
+ def _getgrabfunc(self):
+@@ -561,7 +724,7 @@ class YumRepository(Repository, config.RepoConf):
cookie = self.cachedir + '/' + self.metadata_cookie_fn
self.setAttribute('_dir_setup_metadata_cookie', cookie)
@@ -197502,7 +197554,7 @@ index e5e9ece..ef6d9c6 100644
self._dirSetupMkdir_p(dir)
# persistdir is really root-only but try the make anyway and just
-@@ -714,15 +874,15 @@ class YumRepository(Repository, config.RepoConf):
+@@ -714,15 +877,15 @@ class YumRepository(Repository, config.RepoConf):
local = self.metalink_filename + '.tmp'
if not self._metalinkCurrent():
url = misc.to_utf8(self.metalink)
@@ -197522,7 +197574,7 @@ index e5e9ece..ef6d9c6 100644
raise Errors.RepoError, msg
# Now, we have an old usable metalink, so we can't move to
# a newer repomd.xml ... or checksums won't match.
-@@ -749,9 +909,22 @@ class YumRepository(Repository, config.RepoConf):
+@@ -749,9 +912,22 @@ class YumRepository(Repository, config.RepoConf):
value),
fdel=lambda self: setattr(self, "_metalink", None))
@@ -197546,7 +197598,7 @@ index e5e9ece..ef6d9c6 100644
"""retrieve file from the mirrorgroup for the repo
relative to local, optionally get range from
start to end, also optionally retrieve from a specific baseurl"""
-@@ -768,7 +941,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -768,7 +944,7 @@ class YumRepository(Repository, config.RepoConf):
if local is None or relative is None:
raise Errors.RepoError, \
@@ -197555,7 +197607,7 @@ index e5e9ece..ef6d9c6 100644
if self.cache == 1:
if os.path.exists(local): # FIXME - we should figure out a way
-@@ -778,7 +951,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -778,7 +954,7 @@ class YumRepository(Repository, config.RepoConf):
raise Errors.RepoError, \
"Caching enabled but no local cache of %s from %s" % (local,
@@ -197564,7 +197616,7 @@ index e5e9ece..ef6d9c6 100644
if url:
(scheme, netloc, path, query, fragid) = urlparse.urlsplit(url)
-@@ -796,6 +969,16 @@ class YumRepository(Repository, config.RepoConf):
+@@ -796,6 +972,16 @@ class YumRepository(Repository, config.RepoConf):
except Errors.MediaError, e:
verbose_logger.log(logginglevels.DEBUG_2, "Error getting package from media; falling back to url %s" %(e,))
@@ -197581,7 +197633,7 @@ index e5e9ece..ef6d9c6 100644
if url and scheme != "media":
ugopts = self._default_grabopts(cache=cache)
ug = URLGrabber(progress_obj = self.callback,
-@@ -815,14 +998,9 @@ class YumRepository(Repository, config.RepoConf):
+@@ -815,14 +1001,9 @@ class YumRepository(Repository, config.RepoConf):
range=(start, end),
)
except URLGrabError, e:
@@ -197599,7 +197651,7 @@ index e5e9ece..ef6d9c6 100644
else:
-@@ -835,19 +1013,19 @@ class YumRepository(Repository, config.RepoConf):
+@@ -835,19 +1016,19 @@ class YumRepository(Repository, config.RepoConf):
reget = reget,
checkfunc=checkfunc,
http_headers=headers,
@@ -197626,7 +197678,7 @@ index e5e9ece..ef6d9c6 100644
remote = package.relativepath
local = package.localPkg()
basepath = package.basepath
-@@ -857,15 +1035,30 @@ class YumRepository(Repository, config.RepoConf):
+@@ -857,15 +1038,30 @@ class YumRepository(Repository, config.RepoConf):
return local
misc.unlink_f(local)
@@ -197658,7 +197710,7 @@ index e5e9ece..ef6d9c6 100644
def getHeader(self, package, checkfunc = None, reget = 'simple',
cache = True):
-@@ -933,7 +1126,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -933,7 +1129,7 @@ class YumRepository(Repository, config.RepoConf):
self._metadataCurrent = False
return self._metadataCurrent
@@ -197667,7 +197719,7 @@ index e5e9ece..ef6d9c6 100644
"""check if any file is older than a certain amount of time. Used for
the cachecookie and the mirrorlist
return True if w/i the expiration time limit
-@@ -943,6 +1136,24 @@ class YumRepository(Repository, config.RepoConf):
+@@ -943,6 +1139,24 @@ class YumRepository(Repository, config.RepoConf):
file. If any of them are newer then invalidate the cache
"""
@@ -197692,7 +197744,7 @@ index e5e9ece..ef6d9c6 100644
# -1 is special and should never get refreshed
if expiration_time == -1 and os.path.exists(myfile):
return True
-@@ -991,7 +1202,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -991,7 +1205,7 @@ class YumRepository(Repository, config.RepoConf):
def _cachingRepoXML(self, local):
""" Should we cache the current repomd.xml """
if self.cache and not os.path.exists(local):
@@ -197701,7 +197753,7 @@ index e5e9ece..ef6d9c6 100644
if self.cache or self.metadataCurrent():
return True
return False
-@@ -1020,7 +1231,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1020,7 +1234,7 @@ class YumRepository(Repository, config.RepoConf):
if grab_can_fail:
return None
raise Errors.RepoError, 'Error downloading file %s: %s' % (local, e)
@@ -197710,7 +197762,7 @@ index e5e9ece..ef6d9c6 100644
misc.unlink_f(tfname)
if grab_can_fail:
return None
-@@ -1047,7 +1258,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1047,7 +1261,7 @@ class YumRepository(Repository, config.RepoConf):
parse_can_fail = 'old_repo_XML' in self._oldRepoMDData
if parse_can_fail:
return None
@@ -197719,7 +197771,7 @@ index e5e9ece..ef6d9c6 100644
def _saveOldRepoXML(self, local):
""" If we have an older repomd.xml file available, save it out. """
-@@ -1074,7 +1285,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1074,7 +1288,7 @@ class YumRepository(Repository, config.RepoConf):
# We still want the old data, so we don't download twice. So we
# pretend everything is good until the revert.
if not self.timestamp_check:
@@ -197728,7 +197780,7 @@ index e5e9ece..ef6d9c6 100644
if 'old_repo_XML' not in self._oldRepoMDData:
self._oldRepoMDData = {}
-@@ -1250,7 +1461,6 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1250,7 +1464,6 @@ class YumRepository(Repository, config.RepoConf):
self._revertOldRepoXML()
return False
@@ -197736,7 +197788,7 @@ index e5e9ece..ef6d9c6 100644
if caching:
return False # Skip any work.
-@@ -1260,6 +1470,9 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1260,6 +1473,9 @@ class YumRepository(Repository, config.RepoConf):
return True
def _check_db_version(self, mdtype, repoXML=None):
@@ -197746,7 +197798,7 @@ index e5e9ece..ef6d9c6 100644
if repoXML is None:
repoXML = self.repoXML
if mdtype in repoXML.repoData:
-@@ -1277,11 +1490,11 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1277,11 +1493,11 @@ class YumRepository(Repository, config.RepoConf):
return None
if not file_check:
@@ -197761,7 +197813,7 @@ index e5e9ece..ef6d9c6 100644
if not os.path.exists(local):
local = misc.decompress(local, fn_only=True)
compressed = True
-@@ -1302,6 +1515,17 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1302,6 +1518,17 @@ class YumRepository(Repository, config.RepoConf):
into the delete list, this means metadata can change filename
without us leaking it. """
@@ -197779,7 +197831,7 @@ index e5e9ece..ef6d9c6 100644
def _mdtype_eq(omdtype, odata, nmdtype, ndata):
""" Check if two returns from _get_mdtype_data() are equal. """
if ndata is None:
-@@ -1321,6 +1545,14 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1321,6 +1548,14 @@ class YumRepository(Repository, config.RepoConf):
return True
all_mdtypes = self.retrieved.keys()
@@ -197794,7 +197846,7 @@ index e5e9ece..ef6d9c6 100644
if mdtypes is None:
mdtypes = all_mdtypes
-@@ -1333,8 +1565,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1333,8 +1568,7 @@ class YumRepository(Repository, config.RepoConf):
# Inited twice atm. ... sue me
self._oldRepoMDData['new_MD_files'] = []
@@ -197804,7 +197856,7 @@ index e5e9ece..ef6d9c6 100644
for mdtype in all_mdtypes:
(nmdtype, ndata) = self._get_mdtype_data(mdtype)
-@@ -1371,43 +1602,16 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1371,43 +1605,16 @@ class YumRepository(Repository, config.RepoConf):
# No old repomd data, but we might still have uncompressed MD
if self._groupCheckDataMDValid(ndata, nmdtype, mdtype):
continue
@@ -197853,7 +197905,7 @@ index e5e9ece..ef6d9c6 100644
def _groupLoadRepoXML(self, text=None, mdtypes=None):
""" Retrieve the new repomd.xml from the repository, then check it
-@@ -1421,7 +1625,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1421,7 +1628,7 @@ class YumRepository(Repository, config.RepoConf):
self._commonRetrieveDataMD(mdtypes)
def _mdpolicy2mdtypes(self):
@@ -197862,7 +197914,7 @@ index e5e9ece..ef6d9c6 100644
'group:primary' : ['primary'],
'group:small' : ["primary", "updateinfo"],
'group:main' : ["primary", "group", "filelists",
-@@ -1436,6 +1640,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1436,6 +1643,7 @@ class YumRepository(Repository, config.RepoConf):
if not mdtypes or 'group:all' in mdtypes:
mdtypes = None
else:
@@ -197870,7 +197922,7 @@ index e5e9ece..ef6d9c6 100644
mdtypes = sorted(list(mdtypes))
return mdtypes
-@@ -1446,17 +1651,12 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1446,17 +1654,12 @@ class YumRepository(Repository, config.RepoConf):
except KeyboardInterrupt:
self._revertOldRepoXML() # Undo metadata cookie?
raise
@@ -197890,7 +197942,7 @@ index e5e9ece..ef6d9c6 100644
return self._repoXML
-@@ -1480,7 +1680,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1480,7 +1683,7 @@ class YumRepository(Repository, config.RepoConf):
result = self._getFile(relative='repodata/repomd.xml.asc',
copy_local=1,
local = sigfile,
@@ -197899,7 +197951,7 @@ index e5e9ece..ef6d9c6 100644
reget=None,
checkfunc=None,
cache=self.http_caching == 'all',
-@@ -1508,6 +1708,18 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1508,6 +1711,18 @@ class YumRepository(Repository, config.RepoConf):
raise URLGrabError(-1, 'repomd.xml does not match metalink for %s' %
self)
@@ -197918,7 +197970,7 @@ index e5e9ece..ef6d9c6 100644
def checkMD(self, fn, mdtype, openchecksum=False):
"""check the metadata type against its checksum"""
-@@ -1537,6 +1749,16 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1537,6 +1752,16 @@ class YumRepository(Repository, config.RepoConf):
if size is not None:
size = int(size)
@@ -197935,7 +197987,7 @@ index e5e9ece..ef6d9c6 100644
try: # get the local checksum
l_csum = self._checksum(r_ctype, file, datasize=size)
except Errors.RepoError, e:
-@@ -1545,21 +1767,20 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1545,21 +1770,20 @@ class YumRepository(Repository, config.RepoConf):
raise URLGrabError(-3, 'Error performing checksum')
if l_csum == r_csum:
@@ -197959,7 +198011,7 @@ index e5e9ece..ef6d9c6 100644
""" Internal function, use .retrieveMD() from outside yum. """
# Note that this can raise Errors.RepoMDError if mdtype doesn't exist
# for this repo.
-@@ -1580,15 +1801,19 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1580,15 +1804,19 @@ class YumRepository(Repository, config.RepoConf):
try:
self.checkMD(local, mdtype)
except URLGrabError, e:
@@ -197980,7 +198032,7 @@ index e5e9ece..ef6d9c6 100644
if (os.path.exists(local) or
self._preload_md_from_system_cache(os.path.basename(local))):
-@@ -1597,15 +1822,22 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1597,15 +1825,22 @@ class YumRepository(Repository, config.RepoConf):
return local # it's the same return the local one
try:
@@ -198008,7 +198060,7 @@ index e5e9ece..ef6d9c6 100644
local = self._getFile(relative=remote,
local=local,
copy_local=1,
-@@ -1613,8 +1845,9 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1613,8 +1848,9 @@ class YumRepository(Repository, config.RepoConf):
checkfunc=checkfunc,
text=text,
cache=self.http_caching == 'all',
@@ -198020,7 +198072,7 @@ index e5e9ece..ef6d9c6 100644
if retrieve_can_fail:
return None
raise
-@@ -1622,9 +1855,8 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1622,9 +1858,8 @@ class YumRepository(Repository, config.RepoConf):
if retrieve_can_fail:
return None
raise Errors.RepoError, \
@@ -198031,7 +198083,7 @@ index e5e9ece..ef6d9c6 100644
return local
-@@ -1646,13 +1878,21 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1646,13 +1881,21 @@ class YumRepository(Repository, config.RepoConf):
def getGroups(self):
"""gets groups and returns group file path for the repository, if there
@@ -198056,7 +198108,7 @@ index e5e9ece..ef6d9c6 100644
self._callbacks_changed = True
def setFailureObj(self, failure_obj):
-@@ -1681,7 +1921,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1681,7 +1924,7 @@ class YumRepository(Repository, config.RepoConf):
print "Could not read mirrorlist %s, error was \n%s" %(url, e)
content = []
for line in content:
@@ -198065,7 +198117,7 @@ index e5e9ece..ef6d9c6 100644
continue
mirror = line.rstrip() # no more trailing \n's
mirror = mirror.replace('$ARCH', '$BASEARCH')
-@@ -1701,7 +1941,8 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1701,7 +1944,8 @@ class YumRepository(Repository, config.RepoConf):
fo = None
cacheok = False
@@ -198075,7 +198127,7 @@ index e5e9ece..ef6d9c6 100644
cacheok = True
fo = open(self.mirrorlist_file, 'r')
url = 'file://' + self.mirrorlist_file # just to keep self._readMirrorList(fo,url) happy
-@@ -1713,7 +1954,7 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1713,7 +1957,7 @@ class YumRepository(Repository, config.RepoConf):
ugopts = self._default_grabopts()
try:
fo = urlgrabber.grabber.urlopen(url, **ugopts)
@@ -198084,7 +198136,7 @@ index e5e9ece..ef6d9c6 100644
print "Could not retrieve mirrorlist %s error was\n%s: %s" % (url, e.args[0], misc.to_unicode(e.args[1]))
fo = None
-@@ -1740,7 +1981,11 @@ class YumRepository(Repository, config.RepoConf):
+@@ -1740,7 +1984,11 @@ class YumRepository(Repository, config.RepoConf):
if os.path.exists(destfn):
if os.stat(fn)[stat.ST_CTIME] <= os.stat(destfn)[stat.ST_CTIME]:
return False
@@ -198097,7 +198149,7 @@ index e5e9ece..ef6d9c6 100644
return True
def _preload_file_from_system_cache(self, filename, subdir='',
-@@ -1877,7 +2122,7 @@ def getMirrorList(mirrorlist, pdict = None):
+@@ -1877,7 +2125,7 @@ def getMirrorList(mirrorlist, pdict = None):
try:
fo = urlresolver.urlopen(url, proxies=pdict)
@@ -198107,7 +198159,7 @@ index e5e9ece..ef6d9c6 100644
fo = None
diff --git a/yumcommands.py b/yumcommands.py
-index 4dcbea7..700e76c 100644
+index 4dcbea7..8e0d7d1 100644
--- a/yumcommands.py
+++ b/yumcommands.py
@@ -13,6 +13,7 @@
@@ -198324,7 +198376,19 @@ index 4dcbea7..700e76c 100644
"""
if base.repos.listEnabled():
return
-@@ -152,113 +255,296 @@ def checkEnabledRepo(base, possible_local_files=[]):
+@@ -145,6 +248,11 @@ def checkEnabledRepo(base, possible_local_files=[]):
+ if lfile.endswith(".rpm") and os.path.exists(lfile):
+ return
+
++ # runs prereposetup (which "most" plugins currently use to add repos.)
++ base.pkgSack
++ if base.repos.listEnabled():
++ return
++
+ msg = _('There are no enabled repos.\n'
+ ' Run "yum repolist all" to see the repos you have.\n'
+ ' You can enable repos with yum-config-manager --enable <repo>')
+@@ -152,113 +260,296 @@ def checkEnabledRepo(base, possible_local_files=[]):
raise cli.CliError
class YumCommand:
@@ -198646,7 +198710,7 @@ index 4dcbea7..700e76c 100644
def _add_pkg_simple_list_lens(data, pkg, indent=''):
""" Get the length of each pkg's column. Add that to data.
-@@ -289,22 +575,62 @@ def _list_cmd_calc_columns(base, ypl):
+@@ -289,22 +580,62 @@ def _list_cmd_calc_columns(base, ypl):
return (-columns[0], -columns[1], -columns[2])
class InfoCommand(YumCommand):
@@ -198716,7 +198780,7 @@ index 4dcbea7..700e76c 100644
update_pkgs = {}
inst_pkgs = {}
local_pkgs = {}
-@@ -341,6 +667,7 @@ class InfoCommand(YumCommand):
+@@ -341,6 +672,7 @@ class InfoCommand(YumCommand):
local_pkgs[(po.name, po.arch)] = po
# Output the packages:
@@ -198724,7 +198788,7 @@ index 4dcbea7..700e76c 100644
clio = base.conf.color_list_installed_older
clin = base.conf.color_list_installed_newer
clir = base.conf.color_list_installed_reinstall
-@@ -348,7 +675,9 @@ class InfoCommand(YumCommand):
+@@ -348,7 +680,9 @@ class InfoCommand(YumCommand):
rip = base.listPkgs(ypl.installed, _('Installed Packages'), basecmd,
highlight_na=update_pkgs, columns=columns,
highlight_modes={'>' : clio, '<' : clin,
@@ -198734,7 +198798,7 @@ index 4dcbea7..700e76c 100644
clau = base.conf.color_list_available_upgrade
clad = base.conf.color_list_available_downgrade
clar = base.conf.color_list_available_reinstall
-@@ -356,6 +685,7 @@ class InfoCommand(YumCommand):
+@@ -356,6 +690,7 @@ class InfoCommand(YumCommand):
rap = base.listPkgs(ypl.available, _('Available Packages'), basecmd,
highlight_na=inst_pkgs, columns=columns,
highlight_modes={'<' : clau, '>' : clad,
@@ -198742,7 +198806,7 @@ index 4dcbea7..700e76c 100644
'=' : clar, 'not in' : clai})
rep = base.listPkgs(ypl.extras, _('Extra Packages'), basecmd,
columns=columns)
-@@ -374,7 +704,7 @@ class InfoCommand(YumCommand):
+@@ -374,7 +709,7 @@ class InfoCommand(YumCommand):
for obtup in sorted(ypl.obsoletesTuples,
key=operator.itemgetter(0)):
base.updatesObsoletesList(obtup, 'obsoletes',
@@ -198751,7 +198815,7 @@ index 4dcbea7..700e76c 100644
else:
rop = base.listPkgs(ypl.obsoletes, _('Obsoleting Packages'),
basecmd, columns=columns)
-@@ -389,45 +719,160 @@ class InfoCommand(YumCommand):
+@@ -389,45 +724,160 @@ class InfoCommand(YumCommand):
return 0, []
def needTs(self, base, basecmd, extcmds):
@@ -198917,7 +198981,7 @@ index 4dcbea7..700e76c 100644
return True
-@@ -442,12 +887,25 @@ class GroupsCommand(YumCommand):
+@@ -442,12 +892,25 @@ class GroupsCommand(YumCommand):
'groupinfo' : 'info'}
def getNames(self):
@@ -198943,7 +199007,7 @@ index 4dcbea7..700e76c 100644
return _("Display, or use, the groups information")
def _grp_setup_doCommand(self, base):
-@@ -459,7 +917,7 @@ class GroupsCommand(YumCommand):
+@@ -459,7 +922,7 @@ class GroupsCommand(YumCommand):
except yum.Errors.GroupsError:
return 1, [_('No Groups on which to run command')]
except yum.Errors.YumBaseError, e:
@@ -198952,7 +199016,7 @@ index 4dcbea7..700e76c 100644
def _grp_cmd(self, basecmd, extcmds):
if basecmd in self.direct_commands:
-@@ -470,6 +928,10 @@ class GroupsCommand(YumCommand):
+@@ -470,6 +933,10 @@ class GroupsCommand(YumCommand):
else:
cmd = 'summary'
@@ -198963,7 +199027,7 @@ index 4dcbea7..700e76c 100644
remap = {'update' : 'upgrade',
'erase' : 'remove',
'mark-erase' : 'mark-remove',
-@@ -479,32 +941,76 @@ class GroupsCommand(YumCommand):
+@@ -479,32 +946,76 @@ class GroupsCommand(YumCommand):
return cmd, extcmds
def doCheck(self, base, basecmd, extcmds):
@@ -199050,7 +199114,7 @@ index 4dcbea7..700e76c 100644
cmd, extcmds = self._grp_cmd(basecmd, extcmds)
self._grp_setup_doCommand(base)
-@@ -514,136 +1020,546 @@ class GroupsCommand(YumCommand):
+@@ -514,136 +1025,546 @@ class GroupsCommand(YumCommand):
if cmd == 'list':
return base.returnGroupLists(extcmds)
@@ -199477,12 +199541,9 @@ index 4dcbea7..700e76c 100644
return False
-class ProvidesCommand(YumCommand):
-- def getNames(self):
-- return ['provides', 'whatprovides']
+ def cacheRequirement(self, base, basecmd, extcmds):
+ """Return the cache requirements for the remote repos.
-
-- def getUsage(self):
++
+ :param base: a :class:`yum.Yumbase` object
+ :param basecmd: the name of the command
+ :param extcmds: a list of arguments passed to *basecmd*
@@ -199496,15 +199557,15 @@ index 4dcbea7..700e76c 100644
+ provides command.
+ """
+
-+ def getNames(self):
+ def getNames(self):
+ """Return a list containing the names of this command. This
+ command can be called from the command line by using any of these names.
+
+ :return: a list containing the names of this command
+ """
-+ return ['provides', 'whatprovides']
-+
-+ def getUsage(self):
+ return ['provides', 'whatprovides']
+
+ def getUsage(self):
+ """Return a usage string for this command.
+
+ :return: a usage string for this command
@@ -199621,7 +199682,7 @@ index 4dcbea7..700e76c 100644
ypl = base.returnPkgLists(extcmds)
if (base.conf.obsoletes or
base.verbose_logger.isEnabledFor(logginglevels.DEBUG_3)):
-@@ -675,162 +1591,471 @@ class CheckUpdateCommand(YumCommand):
+@@ -675,162 +1596,471 @@ class CheckUpdateCommand(YumCommand):
base.updatesObsoletesList(obtup, 'obsoletes',
columns=columns)
result = 100
@@ -200123,7 +200184,7 @@ index 4dcbea7..700e76c 100644
def _repo_size(repo):
ret = 0
for pkg in repo.sack.returnPackages():
-@@ -857,7 +2082,10 @@ class RepoListCommand(YumCommand):
+@@ -857,7 +2087,10 @@ class RepoListCommand(YumCommand):
arg = 'enabled'
extcmds = map(lambda x: x.lower(), extcmds)
@@ -200135,7 +200196,7 @@ index 4dcbea7..700e76c 100644
if arg != 'disabled' or extcmds:
try:
# Setup so len(repo.sack) is correct
-@@ -866,6 +2094,13 @@ class RepoListCommand(YumCommand):
+@@ -866,6 +2099,13 @@ class RepoListCommand(YumCommand):
except yum.Errors.RepoError:
if verbose:
raise
@@ -200149,7 +200210,7 @@ index 4dcbea7..700e76c 100644
repos = base.repos.repos.values()
repos.sort()
-@@ -924,111 +2159,108 @@ class RepoListCommand(YumCommand):
+@@ -924,111 +2164,108 @@ class RepoListCommand(YumCommand):
ui_enabled = dhibeg + _('disabled') + hiend
ui_endis_wid = utf8_width(_('disabled'))
@@ -200354,7 +200415,7 @@ index 4dcbea7..700e76c 100644
if not verbose and cols:
# Work out the first (id) and last (enabled/disalbed/count),
-@@ -1088,21 +2320,64 @@ class RepoListCommand(YumCommand):
+@@ -1088,21 +2325,64 @@ class RepoListCommand(YumCommand):
return 0, ['repolist: ' +to_unicode(locale.format("%d", tot_num, True))]
def needTs(self, base, basecmd, extcmds):
@@ -200419,7 +200480,7 @@ index 4dcbea7..700e76c 100644
if len(extcmds) == 0:
base.usage()
raise cli.CliError
-@@ -1147,79 +2422,219 @@ class HelpCommand(YumCommand):
+@@ -1147,79 +2427,219 @@ class HelpCommand(YumCommand):
return help_output
def doCommand(self, base, basecmd, extcmds):
@@ -200648,7 +200709,7 @@ index 4dcbea7..700e76c 100644
vcmd = 'installed'
if extcmds:
vcmd = extcmds[0]
-@@ -1288,7 +2703,7 @@ class VersionCommand(YumCommand):
+@@ -1288,7 +2708,7 @@ class VersionCommand(YumCommand):
ba = base.conf.yumvar['basearch']
cols = []
if vcmd in ('installed', 'all', 'group-installed', 'group-all'):
@@ -200657,7 +200718,7 @@ index 4dcbea7..700e76c 100644
data = base.rpmdb.simpleVersion(not verbose, groups=groups)
lastdbv = base.history.last()
if lastdbv is not None:
-@@ -1307,10 +2722,9 @@ class VersionCommand(YumCommand):
+@@ -1307,10 +2727,9 @@ class VersionCommand(YumCommand):
cols.append(("%s %s" % (_("Group-Installed:"), grp),
str(data[2][grp])))
_append_repos(cols, data[3][grp])
@@ -200670,7 +200731,7 @@ index 4dcbea7..700e76c 100644
data = base.pkgSack.simpleVersion(not verbose, groups=groups)
if vcmd not in ('group-available', 'group-all'):
cols.append(("%s %s/%s" % (_("Available:"), rel, ba),
-@@ -1326,8 +2740,6 @@ class VersionCommand(YumCommand):
+@@ -1326,8 +2745,6 @@ class VersionCommand(YumCommand):
str(data[2][grp])))
if verbose:
_append_repos(cols, data[3][grp])
@@ -200679,7 +200740,7 @@ index 4dcbea7..700e76c 100644
data = {'rid' : {}, 'ver' : {}}
for (rid, ver) in cols:
-@@ -1344,6 +2756,14 @@ class VersionCommand(YumCommand):
+@@ -1344,6 +2761,14 @@ class VersionCommand(YumCommand):
return 0, ['version']
def needTs(self, base, basecmd, extcmds):
@@ -200694,7 +200755,7 @@ index 4dcbea7..700e76c 100644
vcmd = 'installed'
if extcmds:
vcmd = extcmds[0]
-@@ -1352,25 +2772,74 @@ class VersionCommand(YumCommand):
+@@ -1352,25 +2777,74 @@ class VersionCommand(YumCommand):
return True
return vcmd in ('available', 'all', 'group-available', 'group-all')
@@ -200770,7 +200831,7 @@ index 4dcbea7..700e76c 100644
return 2, ["Repeating transaction %u" % (old.tid,)]
def _hcmd_undo(self, base, extcmds):
-@@ -1426,12 +2895,57 @@ class HistoryCommand(YumCommand):
+@@ -1426,12 +2900,57 @@ class HistoryCommand(YumCommand):
def _hcmd_new(self, base, extcmds):
base.history._create_db_file()
@@ -200829,7 +200890,7 @@ index 4dcbea7..700e76c 100644
if extcmds and extcmds[0] not in cmds:
base.logger.critical(_('Invalid history sub-command, use: %s.'),
", ".join(cmds))
-@@ -1444,6 +2958,19 @@ class HistoryCommand(YumCommand):
+@@ -1444,6 +2963,19 @@ class HistoryCommand(YumCommand):
raise cli.CliError
def doCommand(self, base, basecmd, extcmds):
@@ -200849,7 +200910,7 @@ index 4dcbea7..700e76c 100644
vcmd = 'list'
if extcmds:
vcmd = extcmds[0]
-@@ -1468,29 +2995,88 @@ class HistoryCommand(YumCommand):
+@@ -1468,29 +3000,88 @@ class HistoryCommand(YumCommand):
ret = self._hcmd_rollback(base, extcmds)
elif vcmd == 'new':
ret = self._hcmd_new(base, extcmds)
@@ -200938,7 +200999,7 @@ index 4dcbea7..700e76c 100644
chkcmd = 'all'
if extcmds:
chkcmd = extcmds
-@@ -1505,33 +3091,983 @@ class CheckRpmdbCommand(YumCommand):
+@@ -1505,33 +3096,983 @@ class CheckRpmdbCommand(YumCommand):
return rc, ['%s %s' % (basecmd, chkcmd)]
def needTs(self, base, basecmd, extcmds):
@@ -201132,8 +201193,8 @@ index 4dcbea7..700e76c 100644
+ if not extcmds or os.path.isdir(extcmds[0]):
+ return False
+
-+ return True
-+
+ return True
+
+ def cacheRequirement(self, base, basecmd, extcmds):
+ """Return the cache requirements for the remote repos.
+
@@ -201521,8 +201582,8 @@ index 4dcbea7..700e76c 100644
+ if cmd in ('info', 'list'):
+ return InfoCommand().cacheRequirement(base, cmd, extcmds[2:])
+
- return True
-
++ return True
++
+ def cacheRequirement(self, base, basecmd, extcmds):
+ """Return the cache requirements for the remote repos.
+
diff --git a/yum.spec b/yum.spec
index 447cecb..1e326b9 100644
--- a/yum.spec
+++ b/yum.spec
@@ -41,7 +41,7 @@ BuildRequires: bash-completion
Summary: RPM package installer/updater/manager
Name: yum
Version: 3.4.3
-Release: 93%{?dist}
+Release: 94%{?dist}
License: GPLv2+
Group: System Environment/Base
Source0: http://yum.baseurl.org/download/3.4/%{name}-%{version}.tar.gz
@@ -402,6 +402,13 @@ exit 0
%endif
%changelog
+* Wed Jun 12 2013 Zdenek Pavlas <zpavlas at redhat.com> - 3.4.3-94
+- Update to latest HEAD.
+- downloadonly: prefetch also pkg checksums. BZ 973380
+- Fix superfluous dots after "via" in man pages. BZ 972764
+- support "proxy = libproxy" syntax to enable libproxy. BZ 857263
+- checkEnabledRepo: run prereposetup if necessary. BZ 826096
+
* Mon Jun 3 2013 James Antill <james at fedoraproject.org> - 3.4.3-93
- update to latest HEAD.
- Workaround anaconda passing None as group name. BZ 959710.
More information about the scm-commits
mailing list