Message48116
Logged In: YES
user_id=139309
Well in practice, .pth files aren't used a lot (most people will see maybe
wxPython, PIL, and Numeric), so those three os.listdir() probably aren't
going to be significant. If users are creating pth files themselves (which
they probably should be doing, during development), then they'd likely
take advantage of the new features.
As far as power for site admins goes.. why should they have power to
install Python at all? Lots of things an admin could do can cause
surprises.
PYTHONPATH is only useful when dealing with the command prompt
directly, which is probably not the case for users of Mac OS X and
Windows. It shouldn't have to be, anyway. Mac OS X doesn't even
ship with a GUI interface to edit login environment variables, and the
normal rc scripts aren't run in the context of LaunchServices. Also,
consider the situation where a user of some shared web server is writing
CGI scripts that depend on Numeric installed in their home directory.
They'd need to know to add the following to the top of *EVERY* cgi
script:
import site
import os
site.addsitedir(os.path.expanduser("~/lib/python" + sys.version[:3] + "/
site-packages"))
If the admin had configured a directory to put things by installing a .pth
file that pointed there, they simply would have to tell users what flags to
pass to distutils.
For Mac OS X, there is a workaround, in that ~/Library/Python/2.X/site-
packages is a second site dir, but this doesn't need to be a workaround
and should be available elsewhere. |
|
Date |
User |
Action |
Args |
2007-08-23 15:42:32 | admin | link | issue1174614 messages |
2007-08-23 15:42:32 | admin | create | |
|