A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-February/019997.html below:

[Python-Dev] Order that site-packages is added to sys.path

[Python-Dev] Order that site-packages is added to sys.path [Python-Dev] Order that site-packages is added to sys.pathGreg Ward gward@python.net
Tue, 12 Feb 2002 10:27:24 -0500
On 12 February 2002, Barry A. Warsaw said:
> The standalone email package is a simple distutils thingie with a
> directory and a bunch of .py files.  distutils sticks this in
> site-packages.  But an "import email" will always get the standard
> library version instead of the site-packages version because site.py
> /appends/ site-packages to sys.path instead of prepending it.
> 
> I can work around this by adding my own path-hacking code before any
> import of email.* modules.  This is a bit ugly because now it means
> that the proper functioning of the application depends on import
> order, and that's nasty.

Looong ago, I tried to persuade Guido that giving the Distutils the
power to override standard library modules would, on rare occasions, be
a good and useful thing.  (Yet another idea stolen from Perl's
MakeMaker, which can do precisely that.  Sometimes, it's useful.)  Guess
who won?

        Greg
-- 
Greg Ward - just another Python hacker                  gward@python.net
http://starship.python.net/~gward/
A closed mouth gathers no foot.



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4