On 7 July 2017 at 22:23, Koos Zevenhoven wrote:
> On Fri, Jul 7, 2017 at 7:28 AM, Nick Coghlan wrote:
>>
>>
>> As a result, our advice is to *avoid* trying to come up with systemic
>> fixes for structured exception handling, and instead focus on specific
>> use cases of "I want *this* exception t
I want to use abstractmethod, but I have my own metaclasses and I don't
want to build composite metaclasses using abc.ABCMeta.
Thanks to PEP 487, one approach is to facator out the abstractmethod checks
from ABCMeta into a regular (non-meta) class. So, my first suggestion is
to split abc.ABC i
2017-06-25 Greg Ewing dixit:
> > (2) There's a *specific* problem with property where a bug in your
> > getter or setter that raises AttributeError will be masked,
> > appearing as if the property itself doesn't exist.
[...]
> Case 2 needs to be addressed within the method concerned on a
> case-
On Fri, Jul 7, 2017 at 7:28 AM, Nick Coghlan wrote:
>
> As a result, our advice is to *avoid* trying to come up with systemic
> fixes for structured exception handling, and instead focus on specific
> use cases of "I want *this* exception type to have *that* attribute
> for *these* reasons". Thos
On 7 July 2017 at 04:54, Jeff Walker wrote:
> Here is an example:
>
> class NameError(BaseException):
> pass
>
> try:
> raise NameError('welker', db='users', template='{0}: unknown {db}.')
> except NameError as e:
> unknown_name = e.args[0]
> missing_fr