[Trac-tickets] [The Trac Project] #2137: Setuptools fail on windows
with mod_python
The Trac Project
noreply at edgewall.com
Wed Sep 28 04:21:33 CDT 2005
#2137: Setuptools fail on windows with mod_python
-----------------------------------------------+----------------------------
Reporter: Gytis Raciukaitis <gytis at inre.lt> | Owner: jonas
Type: defect | Status: new
Priority: normal | Milestone:
Component: general | Version: devel
Severity: critical | Keywords: |
-----------------------------------------------+----------------------------
The error reported looks like this:
{{{
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: Traceback (most recent call last):
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\Lib\\site-
packages\\mod_python\\apache.py", line 299, in HandlerDispatch\n result
= object(req)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\Lib\\site-
packages\\trac\\web\\modpython_frontend.py", line 199, in handler\n env
= get_environment(mpr, project_opts)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\Lib\\site-
packages\\trac\\web\\main.py", line 338, in get_environment\n return
_open_environment(env_path, threaded)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\Lib\\site-
packages\\trac\\web\\main.py", line 51, in _open_environment\n
env_cache[env_path] = open_environment(env_path)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\lib\\site-
packages\\trac\\env.py", line 354, in open_environment\n env =
Environment(env_path)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\lib\\site-
packages\\trac\\env.py", line 77, in __init__\n from trac.loader import
load_components
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "C:\\Python23\\lib\\site-
packages\\trac\\loader.py", line 20, in ?\n import pkg_resources
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "c:\\python23\\lib\\site-
packages\\setuptools-0.6a2-py2.3.egg\\pkg_resources.py", line 2146, in ?\n
working_set = WorkingSet()
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "c:\\python23\\lib\\site-
packages\\setuptools-0.6a2-py2.3.egg\\pkg_resources.py", line 343, in
__init__\n self.add_entry(entry)
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "c:\\python23\\lib\\site-
packages\\setuptools-0.6a2-py2.3.egg\\pkg_resources.py", line 358, in
add_entry\n for dist in find_distributions(entry, True):
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: File "c:\\python23\\lib\\site-
packages\\setuptools-0.6a2-py2.3.egg\\pkg_resources.py", line 1372, in
find_on_path\n for entry in os.listdir(path_item):
[Wed Sep 28 11:15:20 2005] [error] [client 192.168.0.151] PythonHandler
trac.web.modpython_frontend: WindowsError: [Errno 123] The filename,
directory name, or volume label syntax is incorrect: '\\\\\\\\*.*'
}}}
Looking deeper into it i found out that sys.path[0] is the problem,
because it is initialized to "/". I fixed the problem locally by removing
this element from sys.path in env.py.
--
Ticket URL: <http://projects.edgewall.com/trac/ticket/2137>
The Trac Project <http://trac.edgewall.com/>
More information about the Trac-Tickets
mailing list