wangshen2014 / pywebsocket

Automatically exported from code.google.com/p/pywebsocket
0 stars 0 forks source link

Don't display a stacktrace when pywebsocket is killed by a KeyboardInterrupt #93

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I don't think it's particularly useful to display a stacktrace when I kill 
pywebsocket using ctrl-c.

At least as we use it at Mozilla, pywebsocket takes a few seconds to shut down 
after receiving a SIGINT, so the backtrace doesn't show up until after I get my 
prompt back and start typing my next command.

Original issue reported on code.google.com by justin.l...@gmail.com on 6 May 2011 at 6:16

GoogleCodeExporter commented 9 years ago

Original comment by justin.l...@gmail.com on 6 May 2011 at 6:18

Attachments:

GoogleCodeExporter commented 9 years ago
Hi, Justin,

Thank you for the feedback and the patch. But I think the stack trace is useful
to know that the program is stopped at the expected place.

Original comment by yuzo@chromium.org on 9 May 2011 at 1:39

GoogleCodeExporter commented 9 years ago
Yes, it's not always useful since it usually just shows stack to select.select 
in SocketServer. But as far as it's not harmful, I'd like to keep it for when 
the server gets stuck for some reason. Is it so annoying?

Original comment by tyoshino@chromium.org on 9 May 2011 at 11:48

GoogleCodeExporter commented 9 years ago
> Is it so annoying?

Do you mean to a normal person, or an obsessive-compulsive programmer type?  :)

What would you think about putting a try/except/exit around the select.select 
call?

Original comment by justin.l...@gmail.com on 9 May 2011 at 8:25

GoogleCodeExporter commented 9 years ago
I managed to hack around this using a wrapper process, so I'm happy leaving it 
wontfix.  :)

Original comment by justin.l...@gmail.com on 13 May 2011 at 8:46