Patches item #2092722, was opened at 2008-09-04 18:09
Message generated for change (Comment added) made by mhammond
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=551956&aid=2092722&group_id=78018
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Hartmut Goebel (htgoebel)
Assigned to: Nobody/Anonymous (nobody)
Summary: pywin32_postinstall.py fails when installing an egg
Initial Comment:
pywin32_postinstall.py fails when installing an egg.
I figured out that LoadSystemModule wants to load
C:\Python25\Lib\site-packages\pywin32_system32\pywintypes25.dll
which doe not exist in an egg.
Enclosed patch used pkg_resources to get the correct directory.
----------------------------------------------------------------------
>Comment By: Mark Hammond (mhammond)
Date: 2009-02-07 12:56
Message:
Sorry for the delay in getting to this. I don't think the patch is quite
correct - eg, on my machine without a pywin32 egg installed:
python -c "from pkg_resources import resource_filename, Requirement;print
resource_filename(Requirement.parse('pywin32'), '')"
...
File "o:\src\python-2.5-svn\lib\ntpath.py", line 90, in join
assert len(path) > 0
TypeError: object of type 'NoneType' has no len()
So we probably need a way to reliably detect if we are being installed
from an egg or not.
Secondly, I'm a little concerned about running the post-install script
automatically. I imagine that many users of pywin32 via an egg will be
using some kind of 'automated' process, possibly in a virtualenv
environment, or stand-alone Zope environment etc. In such cases it doesn't
make sense to perform most of those post-install tasks - even copying those
DLLs to system32 would be inappropriate - in such cases they should *only*
be installed to the python dir and never to system32. Maybe the
post-install script needs to change its behaviour based on being in an egg
or not - which ties in with my initial comment. Any thoughts?
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=551956&aid=2092722&group_id=78018
|