New submission from xiscu <[email protected]>:
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()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
RuntimeError: generator ignored GeneratorExit
...
My proposal here is yield_example_1.py
Thanks
----------
assignee: georg.brandl
components: Documentation
files: yield_example_1.py
messages: 96489
nosy: georg.brandl, xiscu
severity: normal
status: open
title: Yield example doesn't work as is explained in the documentation
type: resource usage
versions: Python 2.6
Added file: http://bugs.python.org/file15576/yield_example_1.py
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue7525>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com