[Distutils] pip and distutils

Marius Gedminas marius at pov.lt
Wed Jan 30 13:35:26 CET 2013


On Tue, Jan 29, 2013 at 12:40:17PM -0500, Donald Stufft wrote:
> 
> 
> On Monday, January 28, 2013 at 5:46 PM, Vraj Mohan wrote:
> 
> > ---------- Forwarded message ----------
> > From: Vraj Mohan <r.vrajmohan at gmail.com (mailto:r.vrajmohan at gmail.com)>
> > Date: Mon, Jan 28, 2013 at 4:31 PM
> > Subject: pip and distutils
> > To: python-list at python.org (mailto:python-list at python.org)
> > 
> > I have created a source distribution using distutils which specifies
> > external packages using:
> > 
> > setup(
> > ...,
> > requires = ['Foo (>= 0.7)', 'Bar (>= 2.4.5)'],
> > ...
> > )
> > 
> > When I use pip to install this distribution, I find that it does not
> > automatically install the packages Foo and Bar. What extra step do I
> > need to perform to have pip automatically install the "required"
> > packages?
> > 
> > I am using Python 3.2.3.
> 
> You're using the distutils2 Syntax but pip is built ontop of setuptools. 
> 
> You want requires  = ["Foo>=0.7", Bar>=2.4.5"]

I think you meant

    install_requires=["Foo >= 0.7", "Bar >= 2.4.5"],

(This also requires that you import setup from setuptools and not
distutils.)

Marius Gedminas
-- 
Look!  Before our very eyes, the future is becoming the past.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: Digital signature
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20130130/2214af9b/attachment.pgp>


More information about the Distutils-SIG mailing list