py2exe issues

M

mark

Since distutils is a recent topic (of sorts), I figured it was time to
post my quandary.

I have a utility I've written, and I wanted to create a standalone
executable from it. I tried using Installer (which I've used in the
past), with no success. Now I'm trying py2exe. I use the bdist_wininst
method (?) and it seems to create all the files. However, nothing
happens when I double-click the .exe file. I saw similar behavior from
Installer, so I'm inclined to think there's something wrong with the
script. It runs fine from my Python directory. I am currently
searching the code for any weird hard-coded pathnames or something like
that, but I don't think that should matter.

All that being said, I'm attaching the script for general perusal, in
the hopes that I might garner some insight from the educated masses.
Apologies in advance for any horrific violations of basic coding
principles, as I have no formal education in programming.

Some pertinent information: This is being run and built on WinXP, using
Python 2.3 and Tk 8.4 (through Tkinter). I will be happy to supply any
additional information required.

- Mark Daley
 
M

Miki Tebeka

Hello Mark,
Now I'm trying py2exe. I use the bdist wininst
method (?) and it seems to create all the files.
I usually use "python setup.py py2exe" and it works fine.
However, nothing
happens when I double-click the .exe file. I saw similar behavior from
Installer, so I'm inclined to think there's something wrong with the
script. It runs fine from my Python directory. I am currently
searching the code for any weird hard-coded pathnames or something like
that, but I don't think that should matter.
Make sure py2exe create a console program and run it from a "cmd"
window.
If there any exception you'll be able to see them.

A wild guess whould be that your script is using some module that
wasn't detected by distutils and you get an ImportError, if this is
the case use the --force-import option of py2exe.

HTH.
Miki
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,173
Messages
2,570,938
Members
47,473
Latest member
pioneertraining

Latest Threads

Top