See <a href="http://docs.python.org/library/exceptions.html">Exception Handling</a> <br><br><div class="gmail_quote">On Wed, Aug 11, 2010 at 11:09 AM, Back9 <span dir="ltr"><<a href="mailto:backgoodoo@gmail.com">backgoodoo@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi,<br>
<br>
I run my py app to display a file's contents, and it is normally very<br>
long.<br>
So I use it like below:<br>
<br>
python myapp.py input_file | more<br>
to see them step by step.<br>
<br>
But when I try to exit it, normally I use Ctrl+ C key to quit it.<br>
Problem is every time I do like it, it shows Traceback message and it<br>
makes my app not professional.<br>
<br>
How do I handle it gracefully.<br>
<br>
TIA<br>
<font color="#888888">--<br>
<a href="http://mail.python.org/mailman/listinfo/python-list" target="_blank">http://mail.python.org/mailman/listinfo/python-list</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Eknath Venkataramani<br>