Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #33386
| From | Roy Smith <roy@panix.com> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: debugging in eclipse |
| Date | 2012-11-15 08:54 -0500 |
| Organization | PANIX Public Access Internet and UNIX, NYC |
| Message-ID | <roy-F45720.08540815112012@news.panix.com> (permalink) |
| References | <b45840eb-f429-4287-905a-76d752d4fe04@googlegroups.com> <mailman.3714.1352986928.27098.python-list@python.org> |
In article <mailman.3714.1352986928.27098.python-list@python.org>, Dave Angel <d@davea.name> wrote: > I'd also add a print statement, just to assure yourself that it's running. My trick to make sure something is running is to add "assert 0". To be fair, I usually start by adding a print statement, as Dave suggests. If I see the output, I know it ran. But if I don't see the output, there's two possibilities. Either it didn't run, or it ran but something snarfed the output and hid it from my eyes. That's common in test frameworks. It's also common in background processes where stdout goes who-knows-where, and it's anybody's guess how the logging config might be borked. On the other hand, an "assert 0" is pretty much guaranteed to produce some visible evidence that it ran. About the only thing that would stop it is if somebody had wrapped the code in a try block which caught AssertionError (or Exception).
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
debugging in eclipse chip9munk@gmail.com - 2012-11-15 04:29 -0800
Re: debugging in eclipse Roy Smith <roy@panix.com> - 2012-11-15 07:49 -0500
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 05:43 -0800
Re: debugging in eclipse Dave Angel <d@davea.name> - 2012-11-15 08:41 -0500
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 05:45 -0800
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 05:45 -0800
Re: debugging in eclipse Roy Smith <roy@panix.com> - 2012-11-15 08:54 -0500
Re: debugging in eclipse aahz@pythoncraft.com (Aahz) - 2012-11-15 07:56 -0800
Re: debugging in eclipse Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-11-15 17:05 +0000
Re: debugging in eclipse alex23 <wuwei23@gmail.com> - 2012-11-15 17:10 -0800
Re: debugging in eclipse Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-11-16 10:30 +0000
Re: debugging in eclipse "Martin P. Hellwig" <martin.hellwig@gmail.com> - 2012-11-15 05:44 -0800
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 05:46 -0800
Re: debugging in eclipse Alister <alister.ware@ntlworld.com> - 2012-11-15 14:21 +0000
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 06:28 -0800
Re: debugging in eclipse Ulrich Eckhardt <ulrich.eckhardt@dominolaser.com> - 2012-11-15 14:43 +0100
Re: debugging in eclipse chip9munk@gmail.com - 2012-11-15 06:27 -0800
csiph-web