dependency confusion

55 views
Skip to first unread message

Ellison Marks

unread,
Dec 18, 2012, 3:08:23 PM12/18/12
to pylons-...@googlegroups.com
I just updated to the new pyramid, and my dependencies have gotten a little screwy. I'm using the ZODB scaffold, which lists zodb3 as on of it's dependencies. This gets pulled in fine, but some other package(I'm not sure which one) is pulling in zodb 4.0, which is an alpha right now, far as I can tell. So now both are installed and I'm not particularly sure how to proceed. I tried spinning up a fresh virtualenv just to check, but the same dependency structure emerged. Advice would be appreciated.

Chris McDonough

unread,
Dec 19, 2012, 6:01:27 AM12/19/12
to pylons-...@googlegroups.com
If you really want to stick with ZODB 3, I'd replace the "ZODB3"
dependency in your project's setup.py with this:

install_requires = [
...,
'ZODB3<=3.10.999', # dont go to ZODB4/ZODB3.11 (same thing) yet
...

Apparently someone released a "ZODB3" package that depends on ZODB
4.X.X. I don't understand the rationale and have no further info on
that, but pinning to ZODB 3.10.X will let you not think about it in the
meantime.

You could alternately do:

install_requires = [
...,
'ZODB',
...

(replace "ZODB3" with "ZODB").. this will get ZODB 4.X.X unconditionally
without involving some ZODB3 wrapper package that depends on it somehow.

- C


Marius Gedminas

unread,
Dec 19, 2012, 9:19:22 AM12/19/12
to pylons-...@googlegroups.com
On Wed, Dec 19, 2012 at 06:01:27AM -0500, Chris McDonough wrote:
> On Tue, 2012-12-18 at 12:08 -0800, Ellison Marks wrote:
> > I just updated to the new pyramid, and my dependencies have gotten a
> > little screwy. I'm using the ZODB scaffold, which lists zodb3 as on of
> > it's dependencies. This gets pulled in fine, but some other
> > package(I'm not sure which one) is pulling in zodb 4.0, which is an
> > alpha right now, far as I can tell. So now both are installed and I'm
> > not particularly sure how to proceed. I tried spinning up a fresh
> > virtualenv just to check, but the same dependency structure emerged.
> > Advice would be appreciated.
>
> If you really want to stick with ZODB 3, I'd replace the "ZODB3"
> dependency in your project's setup.py with this:
>
> install_requires = [
> ...,
> 'ZODB3<=3.10.999', # dont go to ZODB4/ZODB3.11 (same thing) yet
> ...
>
> Apparently someone released a "ZODB3" package that depends on ZODB
> 4.X.X. I don't understand the rationale and have no further info on
> that, but pinning to ZODB 3.10.X will let you not think about it in the
> meantime.

AFAIU ZODB3 was a distribution that contained the following importable
Python packages:

BTrees
ZEO
ZODB
persistent

These are now packaged as individual distributions ("eggs"), with the
ZODB3 egg acting as a transitional package that pulls them all in, so
that apps that used to depend on ZODB3 would continue to work.

Marius Gedminas
--
Ximinez: NOBODY expects the Devops Inquisition! Our chief weapon is
collaboration... collaboration and automated deployments... Our two weapons
are collaboration and automated deployments... and ruthless procrastination....
Our three weapons are collaboration, automated deployments, and ruthless
procrastination... and an almost fanatical devotion to vi.... Our four...no...
Amongst our weapons.... Amongst our weaponry...are such elements as
collaboration, automated deployments.... I'll come in again.
-- Grig Gheorghiu
signature.asc

Ellison Marks

unread,
Dec 19, 2012, 1:42:55 PM12/19/12
to pylons-...@googlegroups.com
Thanks for the advice. I wasn't exactly sure since it appears the scaffold still creates a setup.py that lists bare ZODB3.

Ellison Marks

unread,
Dec 19, 2012, 2:11:55 PM12/19/12
to pylons-...@googlegroups.com
Hmm, slight hiccup. I changed ZODB3 in my setup.py to ZODB, but it's still installing ZODB3 alongside 4 in a fresh virtualenv.

Here's my setup.py for reference:
http://pastebin.com/tVvCtSTf

Chris McDonough

unread,
Dec 19, 2012, 2:20:21 PM12/19/12
to pylons-...@googlegroups.com
pyramid_zodbconn depends on ZODB3. You'll have to use it, or at least
have it around, sorry.

(ps: not really sorry, not our fault, but it sounds good ;-) )

- C



Reply all
Reply to author
Forward
0 new messages