buildout and system packages: a simpler idea?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

buildout and system packages: a simpler idea?

Reinout van Rees
Hi,

Buildout and system packages are apparently hard. Buildout 1.5.x tries
hard to get it working, but I cannot get it to work (reliably), for
instance.

Perhaps the problem is that we're trying too hard. Both buildout 1.5.x
and the osc.recipe.sysegg recipe that I'm using on 1.4.x are trying to
look up packages and trying to include them in the path.

What you normally want is just to use the system's PIL and mapnik and
numpy. All stuff that you really don't want to build from source. So you
assume it is installed with a clicky-clicky installer on windows and
with apt-get on ubuntu.

Why not use this assumption? Add an "assumed-available" option to
buildout that lists the eggs that are assumed to be available locally?
No need to actually search them (which is the thing that breaks 1.5.x
for me). Just make sure the regular python path is in place as the last
item in sys.path.


Possible addition: allow a dotted path as a second parameter after the
"assumed-available" eggs: buildout tries to import that path to check
the availability of the egg that's assumed to be available.


So: if you need system eggs, you won't run buildout without system
paths. Only thing left is to tell buildout that certain eggs are
available locally so that it doesn't search for it. Just assume they're
there and leave it at that.


Reinout

--
Reinout van Rees                    http://reinout.vanrees.org/
[hidden email]             http://www.nelen-schuurmans.nl/
"If you're not sure what to do, make something. -- Paul Graham"

_______________________________________________
Distutils-SIG maillist  -  [hidden email]
http://mail.python.org/mailman/listinfo/distutils-sig
Reply | Threaded
Open this post in threaded view
|

Re: buildout and system packages: a simpler idea?

David Glick
On 9/17/11 4:27 PM, Reinout van Rees wrote:

> Hi,
>
> Buildout and system packages are apparently hard. Buildout 1.5.x tries
> hard to get it working, but I cannot get it to work (reliably), for
> instance.
>
> Perhaps the problem is that we're trying too hard. Both buildout 1.5.x
> and the osc.recipe.sysegg recipe that I'm using on 1.4.x are trying to
> look up packages and trying to include them in the path.
>
> What you normally want is just to use the system's PIL and mapnik and
> numpy. All stuff that you really don't want to build from source. So
> you assume it is installed with a clicky-clicky installer on windows
> and with apt-get on ubuntu.
>
> Why not use this assumption? Add an "assumed-available" option to
> buildout that lists the eggs that are assumed to be available locally?
> No need to actually search them (which is the thing that breaks 1.5.x
> for me). Just make sure the regular python path is in place as the
> last item in sys.path.
>
>
> Possible addition: allow a dotted path as a second parameter after the
> "assumed-available" eggs: buildout tries to import that path to check
> the availability of the egg that's assumed to be available.
>
>
> So: if you need system eggs, you won't run buildout without system
> paths. Only thing left is to tell buildout that certain eggs are
> available locally so that it doesn't search for it. Just assume
> they're there and leave it at that.
collective.recipe.mockedeggs may be of use.
_______________________________________________
Distutils-SIG maillist  -  [hidden email]
http://mail.python.org/mailman/listinfo/distutils-sig
Reply | Threaded
Open this post in threaded view
|

Re: buildout and system packages: a simpler idea?

Reinout van Rees
On 18-09-11 01:44, David Glick wrote:
> collective.recipe.mockedeggs may be of use.

I didn't know that one existed. Sounds like a good candidate.

Only thing that worries me: the version number. Is that mandatory?
Perhaps it is a good idea, but I worry a bit about the possible results.


Reinout

--
Reinout van Rees                    http://reinout.vanrees.org/
[hidden email]             http://www.nelen-schuurmans.nl/
"If you're not sure what to do, make something. -- Paul Graham"

_______________________________________________
Distutils-SIG maillist  -  [hidden email]
http://mail.python.org/mailman/listinfo/distutils-sig
Reply | Threaded
Open this post in threaded view
|

Re: buildout and system packages: a simpler idea?

Benji York
In reply to this post by Reinout van Rees
On Sat, Sep 17, 2011 at 7:27 PM, Reinout van Rees <[hidden email]> wrote:

> Hi,
>
> Buildout and system packages are apparently hard. Buildout 1.5.x tries hard
> to get it working, but I cannot get it to work (reliably), for instance.
>
> Perhaps the problem is that we're trying too hard. Both buildout 1.5.x and
> the osc.recipe.sysegg recipe that I'm using on 1.4.x are trying to look up
> packages and trying to include them in the path.
>
> What you normally want is just to use the system's PIL and mapnik and numpy.
> All stuff that you really don't want to build from source. So you assume it
> is installed with a clicky-clicky installer on windows and with apt-get on
> ubuntu.

There's another thing you might want when using a system Python: to
exclude some packages.  I suspect that's what makes it hard.
--
Benji York
_______________________________________________
Distutils-SIG maillist  -  [hidden email]
http://mail.python.org/mailman/listinfo/distutils-sig
Reply | Threaded
Open this post in threaded view
|

Re: buildout and system packages: a simpler idea?

Reinout van Rees
On 19-09-11 19:24, Benji York wrote:
>> What you normally want is just to use the system's PIL and mapnik and numpy.
>> >  All stuff that you really don't want to build from source. So you assume it
>> >  is installed with a clicky-clicky installer on windows and with apt-get on
>> >  ubuntu.
> There's another thing you might want when using a system Python: to
> exclude some packages.  I suspect that's what makes it hard.

My guess is that that's indeed a very hard task. But not that common. If
you want to use something from your system python, it is more than
reasonable to expect you to keep it somewhat clean and unpolluted by
packages you don't want in most of your buildouts.


Reinout

--
Reinout van Rees                    http://reinout.vanrees.org/
[hidden email]             http://www.nelen-schuurmans.nl/
"If you're not sure what to do, make something. -- Paul Graham"

_______________________________________________
Distutils-SIG maillist  -  [hidden email]
http://mail.python.org/mailman/listinfo/distutils-sig