Author mb_
Recipients SilentGhost, barry, mb_, ncoghlan, rhettinger, yselivanov
Date 2016-08-22.20:04:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1471896274.65.0.348824570548.issue27814@psf.upfronthosting.co.za>
In-reply-to
Content
>an implementation of the vastly *less* common pattern:

Ok, here are some numbers.
My codebase is about 32 kLOC.

$ git grep suppressAllExc |wc -l
20
$ git grep contextlib\\.suppress |wc -l
17

(suppressAllExc being my local version to suppress Exception, but exclude a few)

So _neither_ one is pretty common. And that's not surprising, as exceptions ought to be properly handled most of the time.
However the ratio between the two forms is about 1:1. So I don't agree that it would be "vastly *less* common".

But I do accept if such a thing is not wanted upsteam, Altough it basically is a twoliner. I'll simply have to ship my own (I'll have to do that anyway for older Python versions. meh :)

Thanks for the discussion.
History
Date User Action Args
2016-08-22 20:04:34mb_setrecipients: + mb_, barry, rhettinger, ncoghlan, SilentGhost, yselivanov
2016-08-22 20:04:34mb_setmessageid: <1471896274.65.0.348824570548.issue27814@psf.upfronthosting.co.za>
2016-08-22 20:04:34mb_linkissue27814 messages
2016-08-22 20:04:34mb_create