2017-02-06 23:55:37 -05:00
|
|
|
"""
|
|
|
|
categories: Types,Exception
|
2017-12-12 01:13:39 -05:00
|
|
|
description: Exception.__init__ method does not exist.
|
|
|
|
cause: Subclassing native classes is not fully supported in MicroPython.
|
|
|
|
workaround: Call using ``super()`` instead::
|
|
|
|
|
2018-03-15 00:49:38 -04:00
|
|
|
class A(Exception):
|
|
|
|
def __init__(self):
|
|
|
|
super().__init__()
|
2017-02-06 23:55:37 -05:00
|
|
|
"""
|
2021-03-15 09:57:36 -04:00
|
|
|
|
|
|
|
|
2017-02-06 23:55:37 -05:00
|
|
|
class A(Exception):
|
|
|
|
def __init__(self):
|
|
|
|
Exception.__init__(self)
|
|
|
|
|
2021-03-15 09:57:36 -04:00
|
|
|
|
2017-02-06 23:55:37 -05:00
|
|
|
a = A()
|