From: Noam Yorav-R. <noa...@gm...> - 2010-02-25 09:09:41
|
Hello, I've written a program called DreamPie (http://dreampie.sourceforge.net), and it includes a gtk exception hook which helps users report bugs. It prints the stack trace, to help in finding out what's wrong. Since library.zip doesn't include the .py sources of my application, the stack traces include only line numbers and not the contents. Is it possible to include the source modules of my application (not of all modules) in library.zip, so that stack traces will be more meaningful? Thanks, Noam |
From: Werner F. B. <wer...@fr...> - 2010-02-25 10:19:53
|
Hi Noam, On 25/02/2010 10:09, Noam Yorav-Raphael wrote: > Hello, > > I've written a program called DreamPie > (http://dreampie.sourceforge.net), and it includes a gtk exception > hook which helps users report bugs. It prints the stack trace, to help > in finding out what's wrong. > > Since library.zip doesn't include the .py sources of my application, > the stack traces include only line numbers and not the contents. This is part of an error report I got from a user of my py2exe'd application. Traceback (most recent call last): File "twcbF.pyo", line 1969, in OnStartWineButton File "twcbF.pyo", line 1977, in DoStartWine File "zipextimporter.pyo", line 82, in load_module File "appwine.pyo", line 39, in <module> File "zipextimporter.pyo", line 82, in load_module File "framewwwsearch.pyo", line 17, in <module> File "zipextimporter.pyo", line 82, in load_module File "wx\lib\iewin.pyo", line 15, in <module> File "zipextimporter.pyo", line 82, in load_module File "wx\lib\activex.pyo", line 36, in <module> File "zipextimporter.pyo", line 82, in load_module File "comtypes\__init__.pyo", line 1041, in <module> File "comtypes\__init__.pyo", line 229, in __new__ File "comtypes\__init__.pyo", line 314, in __setattr__ File "comtypes\__init__.pyo", line 617, in _make_methods File "comtypes\GUID.pyo", line 44, in __unicode__ File "\loewis\25\python\Modules\_ctypes\callproc.c", line 757, in GetResult WindowsError: [Error -65535] Windows Error 0xFFFF0001 It looks pretty much identical to the one I get when I run into the same error on my dev machine (i.e. running from within Boa). > > Is it possible to include the source modules of my application (not of > all modules) in library.zip, so that stack traces will be more > meaningful? I don't think so. Werner |
From: Werner F. B. <wer...@fr...> - 2010-02-25 11:02:38
|
On 25/02/2010 11:38, Noam Yorav-Raphael wrote: ... >> It looks pretty much identical to the one I get when I run into the same >> error on my dev machine (i.e. running from within Boa). >> > On my dev machine I get also the lines themselves. It makes it much > easier to understand what's wrong, both for me and for the users. > > > What dev tool are you using, maybe it is a function of the tool providing the source line code? Werner |
From: Noam Yorav-R. <noa...@gm...> - 2010-02-25 11:14:09
|
On Thu, Feb 25, 2010 at 1:02 PM, Werner F. Bruhin <wer...@fr...> wrote: > What dev tool are you using, maybe it is a function of the tool providing > the source line code? > No, it's a function of Python. For example, create a file called example.py with this: ============== def f(): 1/0 f() ============== and run python example.py. I get: Traceback (most recent call last): File "example.py", line 4, in <module> f() File "example.py", line 2, in f 1/0 ZeroDivisionError: integer division or modulo by zero |
From: Werner F. B. <wer...@fr...> - 2010-02-25 11:40:25
|
On 25/02/2010 12:13, Noam Yorav-Raphael wrote: > On Thu, Feb 25, 2010 at 1:02 PM, Werner F. Bruhin<wer...@fr...> wrote: > >> What dev tool are you using, maybe it is a function of the tool providing >> the source line code? >> >> > No, it's a function of Python. For example, create a file called > example.py with this: > > ============== > def f(): > 1/0 > > f() > ============== > > and run python example.py. I get: > > Traceback (most recent call last): > File "example.py", line 4, in<module> > f() > File "example.py", line 2, in f > 1/0 > ZeroDivisionError: integer division or modulo by zero > > > You are right, my glasses must be dirty and my brain defect :-[ . Maybe using a "package" tool is better solution for you then - haven't used them but maybe do a .egg distribution? Werner |
From: Noam Yorav-R. <noa...@gm...> - 2010-02-25 11:49:37
|
On Thu, Feb 25, 2010 at 1:40 PM, Werner F. Bruhin <wer...@fr...> wrote: > Maybe using a "package" tool is better solution for you then - haven't used > them but maybe do a .egg distribution? No, I need a stand-alone executable. |
From: Aahz <aa...@py...> - 2010-02-25 14:02:26
|
On Thu, Feb 25, 2010, Noam Yorav-Raphael wrote: > > I've written a program called DreamPie > (http://dreampie.sourceforge.net), and it includes a gtk exception > hook which helps users report bugs. It prints the stack trace, to help > in finding out what's wrong. > > Since library.zip doesn't include the .py sources of my application, > the stack traces include only line numbers and not the contents. > > Is it possible to include the source modules of my application (not of > all modules) in library.zip, so that stack traces will be more > meaningful? Like Werner, my py2exe applications (as well as py2app) provide full exception tracebacks. For example: 2010-02-24 04:31:52 Eastern Standard Time ERROR Unexpected exception Traceback (most recent call last): File "client\synchronizer.pyc", line 887, in _process_opcode File "client\synchronizer_actions.pyc", line 886, in process HTTPException: http_code: -6 [Could not resolve host: FOO.BAR.com; No data record of requested type] (With the domain replaced, of course.) -- Aahz (aa...@py...) <*> http://www.pythoncraft.com/ "Many customs in this life persist because they ease friction and promote productivity as a result of universal agreement, and whether they are precisely the optimal choices is much less important." --Henry Spencer |
From: Aahz <aa...@py...> - 2010-02-25 14:06:21
|
On Thu, Feb 25, 2010, Noam Yorav-Raphael wrote: > > Since library.zip doesn't include the .py sources of my application, > the stack traces include only line numbers and not the contents. > > Is it possible to include the source modules of my application (not of > all modules) in library.zip, so that stack traces will be more > meaningful? Never mind, I get it now -- that's what happens when I post at 6am. Sorry, I don't have an answer. -- Aahz (aa...@py...) <*> http://www.pythoncraft.com/ "Many customs in this life persist because they ease friction and promote productivity as a result of universal agreement, and whether they are precisely the optimal choices is much less important." --Henry Spencer |