RE: [pyxpcom] Problems with getService
by Mark Hammond other posts by this author
Aug 16 2005 10:26PM messages near this date
view in the new Beta List Site
[pyxpcom] Problems with getService
|
Re: [pyxpcom] Problems with getService
> I just compiled the latest version of pyxpcom on windows. When
> testing it I found that using pyxpcom through mozilla worked
> fine, but when called independently through either regxpcom
> or by invoking python it generated an error. I isolated the problem
> to being able to create a service. In particular, the following
> piece used to work fine, but now generates an error:
The problem may be the lack of an XPCOM registry in the directory pyxpcom
uses. When it initializes XPCOM, it assumes the directory of nspr4.dll (or
possibly a different one depending on the patch version) is the xpcom system
dir. I suspect that in some build configurations this is not true. When
run from Mozilla, Mozilla has already initialized xpcom, so this code is not
hit.
You could try hacking the code to print the xpcom directory Python is using,
and checking that it is incorrect. If so, then hard-code in the correct
directory and see if it works. If it does, we need to work out a better way
than the hard-coding :)
Mark
_______________________________________________
pyxpcom mailing list
pyxpcom@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Stefan Farestam
Mark Hammond
Stefan Farestam
Mark Hammond
Stefan Farestam
|