Red Hat Bugzilla – Bug 451228
Missing versions in RPM requirements
Last modified: 2010-10-04 12:56:02 EDT
Description of problem:
Recently did a "yum upgrade TurboGears" from EPEL5 and received this error when
trying to start a server:
Traceback (most recent call last):
File "./start-myapp.py", line 3, in ?
File "/usr/lib/python2.4/site-packages/pkg_resources.py", line 585, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python2.4/site-packages/pkg_resources.py", line 487, in resolve
raise VersionConflict(dist,req) # XXX put more info here
pkg_resources.VersionConflict: (RuleDispatch 0.5a0.dev-r2115
Looking at rpm requires, it has some unversioned requirements:
but looking at the
these have versioned requirements:
CherryPy >= 2.3.0,<3.0.0alpha
RuleDispatch >= 0.5a0.dev-r2303
SQLAlchemy >= 0.3.10
Manually upgrading the approrpriate packages fixes the issue, but I believe this
ought to be expressed in the rpm metadata so that the initial yum upgrade would
have pulled in the other updates.
Version-Release number of selected component (if applicable):
(had upgraded from TurboGears-1.0.1-2.el5)
Ideally ought to autogenerate the rpm requirements from the egginfo requirements
Created attachment 309225 [details]
Script that autogenerates rpm requirements from egginfo requires.txt
Attached is beginnings of a script that can autogenerate rpm requirements from
an egginfo requires.txt
Output from script gives me:
python-cherrypy >= 2.3.0
python-cherrypy < 3.0.0alpha
python-ruledispatch >= 0.5a0.dev-r2303
python-sqlalchemy >= 0.3.10
Created attachment 309532 [details]
Script to autogenerate virtual provides from an egg directory
Output from script when run on egg dir with extra "SQLAlchemy" arg specified
# Autogenerated metadata from "requires.py
Provides: pythonegg(TurboGears) = 22.214.171.124
Requires: pythonegg(CherryPy) >= 2.3.0
Requires: pythonegg(CherryPy) < 3.0.0alpha
Requires: pythonegg(DecoratorTools) >= 1.4
Requires: pythonegg(FormEncode) >= 0.7.1
Requires: pythonegg(PasteScript) >= 1.6.2
Requires: pythonegg(RuleDispatch) >= 0.5a0.dev-r2303
Requires: pythonegg(setuptools) >= 0.6c2
Requires: pythonegg(simplejson) >= 1.3
Requires: pythonegg(TurboCheetah) >= 1.0
Requires: pythonegg(TurboJson) >= 1.1.2
Requires: pythonegg(TurboKid) >= 1.0.4
Requires: pythonegg(SQLAlchemy) >= 0.3.10
Is the dash in the RuleDispatch version likely to cause problems?
We're trying to have a bit of a clean up of the EPEL bug list. Versioning the Requires for cherrypy ruledispatch and sqlalchemy looks like a fairly sane modification to make to the spec (for EL-5 at least). Since you seem to be doing most of the work on TurboGears these days I've switched the owner to you.
However, I'm willing to do the work on this one and lend a hand in future so have applied for the appropriate ACLs on the EL branches.
Go for it. Note three things:
1) CherryPy has a maximal version as well.
2) We don't need manual versioned requirements if the requirements have been met all along in the repository. Fedora general guidance says not to put the versions in if the version has always been met in the repository. This is harder to figure out with EPEL, though, since we don't keep the first version of the rpms that we built there... so it's okay to be a bit overzealous.
3) If the changes won't harm the Fedora package, please put them in the devel branch for Fedora as well.
TurboGears-1.0.9-3.el5 has been submitted as an update for Fedora EPEL 5.
TurboGears-1.0.9-3.el5 has been pushed to the Fedora EPEL 5 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
su -c 'yum --enablerepo=updates-testing update TurboGears'. You can provide feedback for this update here: https://admin.fedoraproject.org/updates/TurboGears-1.0.9-3.el5
TurboGears-1.0.9-3.el5 has been pushed to the Fedora EPEL 5 stable repository. If problems still persist, please make note of it in this bug report.