Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #105853 > unrolled thread

Re: help with program

Started byTerry Reedy <tjreedy@udel.edu>
First post2016-03-27 11:47 -0400
Last post2016-03-27 11:47 -0400
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: help with program Terry Reedy <tjreedy@udel.edu> - 2016-03-27 11:47 -0400

#105853 — Re: help with program

FromTerry Reedy <tjreedy@udel.edu>
Date2016-03-27 11:47 -0400
SubjectRe: help with program
Message-ID<mailman.88.1459093676.28225.python-list@python.org>
On 3/27/2016 10:18 AM, Bob Gailer wrote:
> The problem with putting input at the end of a program is: if the program
> raises an exception you won't see it.

What you are saying is that putting input() at the end of a program (or 
before any exit point) is insufficient for keeping a window alive if the 
program has a bug that causes an exception.  If that is considered 
possible, wrap the entire code in try-except and print or log the 
exception before using input to keep the window alive.  During 
development, it is easier to just run the program in a persistent 
environment, whether console or IDE such as IDLE.

-- 
Terry Jan Reedy

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web