[issue7525] Yield example doesn't work as is explained in the documentation

2009-12-19 Thread Georg Brandl
Georg Brandl added the comment: This only happens in Python 2.5, where GeneratorExit inherits from Exception. In 2.6, it inherits from BaseException and is therefore not caught by the except clause. -- resolution: -> out of date status: open -> closed

[issue7525] Yield example doesn't work as is explained in the documentation

2009-12-16 Thread xiscu
New submission from xiscu : In the documentation the is: ... >>>generator.throw(TypeError, "spam") TypeError('spam',) >>> generator.close() Don't forget to clean up when 'close()' is called. ... I'm getting: >>>generator.throw(TypeError, "spam") TypeError('spam',) >>> generator.close() Tracebac