On 2014-02-28, at 12:08, Bob Greschke <b...@passcal.nmt.edu> wrote: It doesn't, this would just be more elegant, right? It just seems funny that the interpreter doesn't help out this one little bit more. I'd even say why not just have a Python command that you put in your program (not on the #! line) that tells the interpreter what to globally do with traceback error messages, especially since these things can happen and the program just keep on running. "set stdtraceback to file X". For a non-threaded/non-GUI program it might not be that big of a deal -- it hits a bug and stops -- but for a big Tkinter program you could just keep selecting menus and buttons and never know there was a problem somewhere. Yes there is the logging and the traceback modules and all of that, but that's a lot of duplication of labor. The interpreter already knows everything, you just can't tell it what to do with the messages to make it helpful. It seems like a small oversight to me.
On 2014-02-28, at 09:35, Cam <camfarn...@bitflipper.ca> wrote: > I'm probably not understanding the question. How does what you propose differ > from wrapping your whole application in a try/except so that any uncaught > exceptions result in information being written to error.txt? > > Cam > > On 14-02-28 11:33 AM, Bob Greschke wrote: >> This isn't quite a Tkinter thing, but why can't some clever person (I >> couldn't do it) make it possible for you to put something like this >> >> #! /usr/bin/python -t "/home/me/error.txt",stderr >> >> at the beginning of a Python program and have the interpreter direct all of >> the traceback messages to the file error.txt, and stderr? I've got a 43,000 >> line Tkinter/via X11 program and stupid users that won't tell me when it >> crashes -- if they even notice. Right now we create an xterm on their >> computer then execute and ssh to the server where the program resides. The >> errors come out in that xterm, but if the users quit they are gone. It >> seems like the interpreter would be the smartest place to put something like >> this since it controls everything, and so you don't have to try and guess in >> which section of code you misspelled a variable name and put it in a >> try-except. >> >> Isn't this reasonable? There are all kinds of questions about this problem, >> but never any really good solutions. I like this one. :) I just wouldn't >> have any idea how to do it, or if it's even possible. >> >> Bob >> >> _______________________________________________ >> Tkinter-discuss mailing list >> Tkinter-discuss@python.org >> https://mail.python.org/mailman/listinfo/tkinter-discuss >> > _______________________________________________ > Tkinter-discuss mailing list > Tkinter-discuss@python.org > https://mail.python.org/mailman/listinfo/tkinter-discuss > _______________________________________________ Tkinter-discuss mailing list Tkinter-discuss@python.org https://mail.python.org/mailman/listinfo/tkinter-discuss