Need help: GUI2Exe creates exe apps that won't run on Windows.

Hi Andrea,

I installed GUI2Exe_0.5 and py2exe on a new Windows XP desktop machine,
and I can now compile the wxPython application I develop (I use Python 2.6).

However, when I try to run it, I get: “The application failed to initialize properly (0xc0000142)”

Outlook.jpg

I used GUE2Exe on a small wxPython script (listing below), and it also gives me the above error.

Have you any suggestions how to resolve this ?

Thanks,

Ron.

···

#!/usr/bin/env python

ex01.py

import wx

class App(wx.App):
def OnInit(self):
frame = wx.Frame(parent=None, title=“Hello World! 1”)
panel = wx.Panel(frame)
text = wx.StaticText(panel, -1, “Hello World!”)
text.SetFont(wx.Font(14, wx.SWISS, wx.NORMAL, wx.BOLD))
frame.Show()
return True

app = App(redirect=False)
app.MainLoop()

Hi Ron,

···

http://wiki.wxpython.org/py2exe

Thanks,

Ron.


#!/usr/bin/env python

ex01.py

import wx

class App(wx.App):

def OnInit(self):

    frame = wx.Frame(parent=None, title="Hello World! 1")

    panel = wx.Panel(frame)

    text = wx.StaticText(panel, -1, "Hello World!")

    text.SetFont(wx.Font(14, wx.SWISS, wx.NORMAL, wx.BOLD))

    frame.Show()

    return True

app = App(redirect=False)

app.MainLoop()

To unsubscribe, send email to
or visit
wxPython-users+unsubscribe@googlegroups.com
http://groups.google.com/group/wxPython-users?hl=en

Hi Werner,
The setup.py I have in the root of my GUI2Exe_0.5 directory is the one
that was created when I installed GUI2Exe.
I tried using GUI2Exe utilising the setup.py you suggested, but the
error I get is the same as in the original message.
Bye,
Ron.

···

On Mar 8, 11:22 am, werner <wbru...@free.fr> wrote:

Hi Ron,

On 08/03/2010 09:06, Barak, Ron wrote:> Hi Andrea,
> I installed GUI2Exe_0.5 and py2exe on a new Windows XP desktop machine,
> ...

What is your setup.py for the script below?

IIRC the error I get due to the new manifest MS dll sxs issue with Py2.6
is a bit different, but are you including all the sxs stuff in your
setup.py or your installer?

See:py2exe - wxPyWiki

Werner

Hi Ron,

···

On 10/03/2010 12:13, Ron Barak wrote:

On Mar 8, 11:22 am, werner<wbru...@free.fr> wrote:
   

Hi Ron,

On 08/03/2010 09:06, Barak, Ron wrote:> Hi Andrea,
     

I installed GUI2Exe_0.5 and py2exe on a new Windows XP desktop machine,
...
       

What is your setup.py for the script below?

IIRC the error I get due to the new manifest MS dll sxs issue with Py2.6
is a bit different, but are you including all the sxs stuff in your
setup.py or your installer?

See:py2exe - wxPyWiki

Werner

Hi Werner,
The setup.py I have in the root of my GUI2Exe_0.5 directory is the one
that was created when I installed GUI2Exe.
I tried using GUI2Exe utilising the setup.py you suggested, but the
error I get is the same as in the original message.
   

Can you create a small sample application (MakingSampleApps - wxPyWiki) which shows the problem? If yes, post it somewhere and I will try and see if I can help - maybe there are others which will look at it too.

Werner

Can you create a small sample application
(MakingSampleApps - wxPyWiki) which shows the problem? If
yes, post it somewhere and I will try and see if I can help - maybe
there are others which will look at it too.

Werner- Hide quoted text -

- Show quoted text -

Hi Werner,
The application is inside the first message of this thread.
Bye,
Ron.

He was asking for your setup.py that you use to run py2exe.

···

On 3/11/10 8:51 AM, Ron Barak wrote:

Can you create a small sample application
(MakingSampleApps - wxPyWiki) which shows the problem? If
yes, post it somewhere and I will try and see if I can help - maybe
there are others which will look at it too.

Werner- Hide quoted text -

- Show quoted text -

Hi Werner,
The application is inside the first message of this thread.

--
Robin Dunn
Software Craftsman

Attached setup.py works for me with the application shown in the first message of this thread.

I built using Py2.6.4 and wxPython 2.8.10.1 on Windows 7. I can run the exe from the dist folder on my Win 7 machine, I can also run it on my Win XP machine from a drive mapped to my Win 7 machine.

Are you clearing the dist and build folders, i.e. you don't have some old stuff in there?

Werner

setup.py (3.93 KB)

···

On 11/03/2010 17:51, Ron Barak wrote:

   

Can you create a small sample application
(MakingSampleApps - wxPyWiki) which shows the problem? If
yes, post it somewhere and I will try and see if I can help - maybe
there are others which will look at it too.

Werner- Hide quoted text -

- Show quoted text -
     

Hi Werner,
The application is inside the first message of this thread.

Werner,

Thank you for the sample setup.py. I've been trying to build a sample
app but also create one as a portable app according to the
PortableApp.com format.

So far your script has helped me compile the program so it runs, but
then raises errors because it cannot find all the required files.

Has anyone on this list tried to make a wxPython app Portable?

···

--
Josh English
Joshua.R.English@gmail.com
http://joshenglish.livejournal.com

Hi Josh,

Werner,

Thank you for the sample setup.py. I've been trying to build a sample
app but also create one as a portable app according to the
PortableApp.com format.
   

Had a quick look at that site (with the "s" :wink: http://portableapps.com/) but can't find an overview on how this is supposed to work. Searching for Python on their site gives a few links.

E.g. Python Portable 2.5.2 Development Test 1 | PortableApps.com which seems to indicate that they only have the command line working. Some talk about SPE in that thread, if they got that working that should help you going as I am pretty sure that SPE is wxPython based.

And in this one How to portabilize pygtk and python | PortableApps.com they talk about "cornice" which is supposed to be Python based and build as an exe (using py2exe? or ?).

Werner

···

On 14/03/2010 04:32, Josh English wrote:

As far as I can tell, any wxPython app which is frozen with py2exe is portable, in the sense that it requires no installation except to be present in a directory somewhere, as long as all the necessary dlls are included in the application directory. I have deployed several py2exe’d wxPython apps on CDs simply by putting all the files in the root directory and including an appropriate autorun.inf file to automatically run the exe when the CD is inserted in the drive. They all worked just fine with no extra magic.

···

On Sat, Mar 13, 2010 at 11:32 PM, Josh English joshua.r.english@gmail.com wrote:

Has anyone on this list tried to make a wxPython app Portable?


Best Regards,
Michael Moriarity

Hi Josh,

Has anyone on this list tried to make a wxPython app Portable?

Task Coach (GPL) is available as PortableApp. It is built
automatically as part of our build process.

Here are the sources:

(prefix this to the files mentioned below)

Makefile contains targets for building different distributions.
Makefile invokes the make.py script for most building stuff. In turn
make.py uses distutils commands for building distributions. For some
distribution we have developed our own distutils commands. These
commands are located in buildlib, e.g. buildlib/bdist_portableapps.py.
Files used by these build commands are located in build.in. E.g.
build.in/portableapps/*.

HTH, Frank

···

2010/3/14 Josh English <joshua.r.english@gmail.com>:

Hi Frank,

While visiting your site, I noticed that TaskCoach is also available as
an iPhone/iPad app.

Is your iPhone/iPad version of TaskCoach also based on Python?

Thank you,
Malcolm

Hi Malcom,

···

2010/3/14 <python@bdurham.com>:

While visiting your site, I noticed that TaskCoach is also available as
an iPhone/iPad app.

Is your iPhone/iPad version of TaskCoach also based on Python?

No, it is written in Objective-C by my fellow Task Coach developer
Jérôme Laheurte. Apple doesn't allow interpreted languages on the
iPhone as far as I know.

Cheers, Frank

Hi Frank,

Hi Malcom,

While visiting your site, I noticed that TaskCoach is also available as
an iPhone/iPad app.

Is your iPhone/iPad version of TaskCoach also based on Python?

No, it is written in Objective-C by my fellow Task Coach developer
Jérôme Laheurte. Apple doesn't allow interpreted languages on the
iPhone as far as I know.

Actually, there is an app using python + pygame that got into the app store by using a Python -> C(++) compiler. See here:

http://www.philhassey.com/blog/2009/12/19/elephants-first-python-pygame-game-submitted-to-app-store/

Regards,

Kevin

···

On Mar 14, 2010, at 2:19 PM, Frank Niessink wrote:

2010/3/14 <python@bdurham.com>:

Cheers, Frank

--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en

Frank,

Thank you for the hint. I downloaded the source, because I saw in the
forums TC was built on wx, but the code was so, well, large, I
couldn't even begin to search for the right area.

Josh

···

On Sun, Mar 14, 2010 at 1:24 PM, Frank Niessink <frank@niessink.com> wrote:

Hi Josh,

Makefile contains targets for building different distributions.
Makefile invokes the make.py script for most building stuff. In turn
make.py uses distutils commands for building distributions. For some
distribution we have developed our own distutils commands. These
commands are located in buildlib, e.g. buildlib/bdist_portableapps.py.
Files used by these build commands are located in build.in. E.g.
build.in/portableapps/*.

HTH, Frank

--
Josh English
Joshua.R.English@gmail.com

Kevin,

Actually, there is an app using python + pygame that got into the app store by using a Python -> C(++) compiler. See here:
Phil Hassey » Blog Archive » Elephants! First python + pygame game submitted to App Store :)

Thanks for that link - very interesting. I wasn't aware of the TinyPyC.

Regards,
Malcolm

That's all PortablePython, which I do have but I don't use as much as
I should. In fact, I could run all my scripts as scripts with PP and
save myself this headache, but I wanted to challenge myself with this
task.

So far, the task is winning.

···

On Sun, Mar 14, 2010 at 3:28 AM, werner <wbruhin@free.fr> wrote:

Hi Josh,

On 14/03/2010 04:32, Josh English wrote:

Werner,

Thank you for the sample setup.py. I've been trying to build a sample
app but also create one as a portable app according to the
PortableApp.com format.

Had a quick look at that site (with the "s" :wink: http://portableapps.com/)
but can't find an overview on how this is supposed to work. Searching for
Python on their site gives a few links.

E.g. Python Portable 2.5.2 Development Test 1 | PortableApps.com which seems to indicate that they
only have the command line working. Some talk about SPE in that thread, if
they got that working that should help you going as I am pretty sure that
SPE is wxPython based.

And in this one How to portabilize pygtk and python | PortableApps.com they talk about "cornice"
which is supposed to be Python based and build as an exe (using py2exe? or
?).

Werner

--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en

--
Josh English
Joshua.R.English@gmail.com

Hi Kevin,

···

2010/3/14 Kevin Ollivier <kevin-lists@theolliviers.com>:

Actually, there is an app using python + pygame that got into the app store by using a Python -> C(++) compiler. See here:

Phil Hassey » Blog Archive » Elephants! First python + pygame game submitted to App Store :)

Interesting, but I'm not sure how that would work when porting a wx app...

Cheers, Frank

Hi Josh,

Frank,

Thank you for the hint. I downloaded the source, because I saw in the
forums TC was built on wx, but the code was so, well, large, I
couldn't even begin to search for the right area.

Oh, what might be it is that not all build files are included in the
source distribution. The source distribution is meant for people to
run Task Coach from source, not to build other distributions. You
should really check out the sources from Subversion:

svn co Task Coach download | SourceForge.net
cd taskcoach
more HACKING.txt
more Makefile
more make.py
ls buildlib
ls build.in
etc...

Cheers, Frank

···

2010/3/15 Josh English <joshua.r.english@gmail.com>:

I'll give it a try. I'm on dialup, so SVN doesn't always work out. too
many timeouts. I'm upgrading to DSL soon, though.

···

On Mon, Mar 15, 2010 at 2:23 PM, Frank Niessink <frank@niessink.com> wrote:

Hi Josh,

2010/3/15 Josh English <joshua.r.english@gmail.com>:

Frank,

Thank you for the hint. I downloaded the source, because I saw in the
forums TC was built on wx, but the code was so, well, large, I
couldn't even begin to search for the right area.

Oh, what might be it is that not all build files are included in the
source distribution. The source distribution is meant for people to
run Task Coach from source, not to build other distributions. You
should really check out the sources from Subversion:

svn co Task Coach download | SourceForge.net
cd taskcoach
more HACKING.txt
more Makefile
more make.py
ls buildlib
ls build.in
etc...

Cheers, Frank

--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en

--
Josh English
Joshua.R.English@gmail.com