This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pablogsal
Recipients Mark.Shannon, oleksandr.suvorov, pablogsal
Date 2020-05-22.11:21:09
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1590146469.03.0.151737456525.issue40728@roundup.psfhosted.org>
In-reply-to
Content
> but if exc variable is only available in except block why then it shadows
the function variable name?

Because the except block does not create a new scope and therefore when you do 'except as x' it does an assignment to x in the same scope as the function.
History
Date User Action Args
2020-05-22 11:21:09pablogsalsetrecipients: + pablogsal, Mark.Shannon, oleksandr.suvorov
2020-05-22 11:21:09pablogsalsetmessageid: <1590146469.03.0.151737456525.issue40728@roundup.psfhosted.org>
2020-05-22 11:21:09pablogsallinkissue40728 messages
2020-05-22 11:21:09pablogsalcreate