Author martin.panter
Recipients benjamin.peterson, brett.cannon, emptysquare, gvanrossum, haypo, larry, martin.panter, ncoghlan, pitrou, serhiy.storchaka, yselivanov
Date 2015-11-17.21:36:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1447796200.64.0.675233296293.issue25612@psf.upfronthosting.co.za>
In-reply-to
Content
Regarding the second bug, did you consider that the exception thrown to the generator can already have __context__ set?

try:
    try: raise ValueError("Context outside of generator")
    except ValueError as ex: raise SubError() from ex
except SubError as ex:
    coro.throw(ex)  # ex.__context__ is a ValueError

I guess either one context could trump the other, or we could to follow the chain of contexts and append the other chain at the end. Both these ideas seem a bit ugly though.
History
Date User Action Args
2015-11-17 21:36:40martin.pantersetrecipients: + martin.panter, gvanrossum, brett.cannon, ncoghlan, pitrou, haypo, larry, benjamin.peterson, serhiy.storchaka, yselivanov, emptysquare
2015-11-17 21:36:40martin.pantersetmessageid: <1447796200.64.0.675233296293.issue25612@psf.upfronthosting.co.za>
2015-11-17 21:36:40martin.panterlinkissue25612 messages
2015-11-17 21:36:40martin.pantercreate