New submission from Daniel Crowley-Wilson <[EMAIL PROTECTED]>: The code sample in Tutorial section 8.3 (Handling Exceptions) doesn't match the description. Removing the "break" line from the code sample would make the sample perform according to the description. Found in the windows doc\python25.chm file.
Original text is below: *** It is possible to write programs that handle selected exceptions. Look at the following example, which asks the user for input until a valid integer has been entered, but allows the user to interrupt the program (using Control-C or whatever the operating system supports); note that a user-generated interruption is signalled by raising the KeyboardInterrupt exception. >>> while True: ... try: ... x = int(raw_input("Please enter a number: ")) ... break ... except ValueError: ... print "Oops! That was no valid number. Try again..." ... ---------- assignee: georg.brandl components: Documentation messages: 67281 nosy: dcw303, georg.brandl severity: normal status: open title: Python 2.5 Documentation error in Tutorial section 8.3 versions: Python 2.5 __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2955> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com