38 lines
1.2 KiB
Plaintext
38 lines
1.2 KiB
Plaintext
From: MHammond at skippinet.com.au (Mark Hammond)
|
|
Date: Wed, 14 Apr 1999 09:39:50 +1000
|
|
Subject: site.py & COM startup
|
|
References: <U+ok8DAslzE3EwUd@jessikat.demon.co.uk>
|
|
Message-ID: <7f0kin$ben$1@m2.c2.telstra-mm.net.au>
|
|
X-UID: 1582
|
|
|
|
Robin Becker wrote in message ...
|
|
>using Mark Hammond's win32com for a server I find that the installation
|
|
path is not
|
|
>automatically in sys.path so my base .pth files are missed and I get
|
|
troubles.
|
|
>
|
|
>I hacked site.py to fix this using the fact that sys.prefix == '' when
|
|
running a com
|
|
>server (I guess inproc).
|
|
|
|
It is indeed when run as an inproc. The problem is that Python uses the
|
|
current executable to try and deduce the Python home. When Python is being
|
|
used as a COM server, the host executable could be _anything_, and therefore
|
|
cant be used to locate the Python home.
|
|
|
|
So, I would like to fix this once and for all in the COM stuff, but I cant
|
|
work out a reasonable strategy for locating the Python home.
|
|
|
|
Also, FYI: As of build 124 and later of my extensions, when you register a
|
|
COM object its path is now also automatically saved away, and automatically
|
|
used as the object is created - thus, no more errors due to your COM object
|
|
not being on the PythonPath...
|
|
|
|
Mark.
|
|
|
|
|
|
|
|
|
|
|
|
|