[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Compiled Python hookscript error: "terminate it in an unusual way"

From: Anders J. Munch <ajm_at_flonidan.dk>
Date: 2005-10-05 15:42:58 CEST

>
> I have the Python script "check-case-insensitive"
> working. Now I am trying to compile it with the
> py2exe compiler. I get an error when I try to commit
> when the hookscript calls the compiled script's
> executable. I think a clue is that when I build the
> executable ("invoking py2exe"), I get a warning that a
> module ("svn") appears to be missing. I'm trying to
> run this on the machine that built the exe, so I am
> assuming all the dll dependencies are being met.
>
> Any suggestions? I don't know much about Python.
>
>
>
> ====================================================
> setup.py:
> ----------------------------------------------------
> # setup.py
> from distutils.core import setup
> import py2exe
>
> setup(console=["check-case-insensitive.py"],
> zipfile=None)

py2exe may be failing to detect full dependencies, therefore including
too few files.

Try adding a packages option to setup:
setup(options={"py2exe": {"packages": ["svn", "encodings"]}},
         console=..etc..

This will tell py2exe to include the svn and encodings packages in
their entirety, rather than trying to detect what is used and what is
not.

About your specific error message, I found this comment in the CPython
sources, in the exit cleanup code:

         * XXX If a __del__ or weakref callback is triggered here, and tries to
         * XXX import a module, bad things can happen, because Python no
         * XXX longer believes it's initialized.
         * XXX Fatal Python error: Interpreter not initialized (version mismatch?)
         * XXX is easy to provoke that way.

It may be that some missing DLL or module is causing initialisation to
fail, leaving a module in a state where it cannot clean up properly on
CPython exit.

If the packages option doesn't help, try the py2exe mailing list for a
further investigation.

- Anders

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Oct 5 15:49:05 2005

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.