[Python-Dev] .pth files are evil

Chris Withers chris at simplistix.co.uk
Fri May 1 12:26:29 EDT 2009

M.-A. Lemburg wrote:
> """
> If the package really requires adding one or more directories on sys.path (e.g.
> because it has not yet been structured to support dotted-name import), a "path
> configuration file" named package.pth can be placed in either the site-python or
> site-packages directory.
> ...
> A typical installation should have no or very few .pth files or something is
> wrong, and if you need to play with the search order, something is very wrong.
> """

I'll say! I think .pth files are absolute evil and I wish they could 
just be banned.

+1 on anything that makes them closer to going away or reduces the 
possibility of yet another similar feature from hurting the 
comprehensibility of a python setup.


Simplistix - Content Management, Zope & Python Consulting
            - http://www.simplistix.co.uk

More information about the Python-list mailing list