[issue14911] generator.throw() documentation inaccurate

2018-10-17 Thread Cheryl Sabella
Cheryl Sabella added the comment: It seems that this patch was close to being merged. Would it be helpful for me to create a PR for it over 3.8? Thanks! -- nosy: +cheryl.sabella ___ Python tracker

[issue14911] generator.throw() documentation inaccurate

2015-12-18 Thread Martin Panter
Martin Panter added the comment: This one is based on the public 3.5 branch, so should work. I corrected a small typo made in the previous patch. -- versions: -Python 3.4 Added file: http://bugs.python.org/file41360/throw-3x.v3.patch ___ Python

[issue14911] generator.throw() documentation inaccurate

2015-12-17 Thread Yury Selivanov
Yury Selivanov added the comment: Martin, could you please rebase your patch on top of recent cpython default branch, so that a 'review' link appears? -- ___ Python tracker

[issue14911] generator.throw() documentation inaccurate

2015-12-04 Thread Martin Panter
Martin Panter added the comment: Changes in throw-3x.v2.patch: * Split into two signatures * Added parallel coroutine.throw(value) signature * *Value* should be an exception instance; drop mentioning other options * Default value is instantiated from *type* * __traceback__ can be cleared *

[issue14911] generator.throw() documentation inaccurate

2015-11-17 Thread Martin Panter
Martin Panter added the comment: I can’t really comment on the 2.7 version, because I’m not too familiar with Python 2 exceptions. For Python 3, is there any reason to bless the None, tuple or non-exception cases as the exception “value” argument? IMO these just make things too complicated

[issue14911] generator.throw() documentation inaccurate

2015-06-20 Thread Martin Panter
Martin Panter added the comment: See Issue 13213 for some analysis of the behaviour of different combinations of arguments. The docstring should be changed if necessary, but in this case I don’t see what needs changing. The argument names perhaps, just for consistency’s sake? --

[issue14911] generator.throw() documentation inaccurate

2014-02-04 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Note that the docstring does not match the doc: PyDoc_STRVAR(throw_doc, throw(typ[,val[,tb]]) - raise exception in generator,\n\ return next yielded value or raise StopIteration.); Should I change the docstring too? --

[issue14911] generator.throw() documentation inaccurate

2014-02-03 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Here's one for 2.7. I'm still looking at 3. The funny thing is that the signature of generator.throw reflects 2.x conventions. I'm figuring out if it can be used with the .with_traceback() idiom -- keywords: +patch Added file:

[issue14911] generator.throw() documentation inaccurate

2014-02-03 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: And 3.x -- Added file: http://bugs.python.org/file33888/3x.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14911 ___

[issue14911] generator.throw() documentation inaccurate

2014-02-03 Thread Yury Selivanov
Yury Selivanov added the comment: I like the patches, except the example in 3x.diff. Please see the review. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14911 ___

[issue14911] generator.throw() documentation inaccurate

2014-01-31 Thread Yury Selivanov
Yury Selivanov added the comment: Kristjan, can you write a patch for this? -- nosy: +yselivanov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14911 ___

[issue14911] generator.throw() documentation inaccurate

2012-05-25 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: the documentation for generator.throw() does not mention the fact that it has the same semantics for the three arguments as a raise expression has. The first two arguments can be: throw(exc_type, None) throw(exc_type, value)

[issue14911] generator.throw() documentation inaccurate

2012-05-25 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- stage: - needs patch versions: -Python 3.1, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14911 ___