Hi Harmut,

Thanks for replying.


On Tue, May 14, 2013 at 7:52 PM, Hartmut Goebel
<[email protected]>wrote:

>  Am 14.05.2013 06:14, schrieb Laurence:
>
> #     app.setWindowIcon(QtGui.QIcon(':/icons/icon.png'))
>
>
> I Doubt, this is working at all. AFAIK ":/" ist not a valid path-begin on
> any system.
>

The :/ is being used because the icon is saved as a PyQt resource. :/ is
the standard way to refer to PyQT resources. Remember, that I said from the
outset that the program works without problem before I try to bundle it
with PyInstaller. In other words, the regular script works fine. The path
is *not* the issue.


>
> Also you should split this into two statements, using an intermediate
> assign. So you can test whether QIcon() *or* setWindowIcon is failing --
> which might be a big difference for debugging.
>

In my original post, I wrote " I also know that the QIcon is created
properly". I did split the two statements and confirmed that QIcon is
working correctly even after bundling with PyInstaller. The problem is with
setWindowIcon. And, I repeat, the original program runs fine. The crash
only happens after I bundle it with PyInstaller 2.0. (And with PyInstaller
1.5.1, it runs fine, too).


> the PyInstaller single-dir and single-file bundles crash with no error
> reported. (Before bundling the app, everything works fine in the standard
> console).
>
>
> What do you mean wirh "standard console"? Are you running on Windows? Do
> you get error-output when starting the program from the console/shell?
>

I should clarify what I mean. I am on Windows. I can run the original
program (without errors) through my IDE (Eclipse), but for simplicity I can
also run the program via the console. In short, the original program runs
with no errors at all. It is fine.

After bundling the program, I add the console option to the one-file or
one-dir build. This lets me see what happens when it runs. When I double
click the executable, the bundled program crashes. The error report is
"Python unexpectedly stopped working" (or something to that effect).

So, the problem seems to be setWindowIcon in PyInstaller 2.0

Laurence.

-- 
You received this message because you are subscribed to the Google Groups 
"PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pyinstaller?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to