summaryrefslogtreecommitdiff
path: root/ports/esp8266/modules/flashbdev.py
diff options
context:
space:
mode:
authorKevin Köck <kevin.koeck@gmx.net>2020-03-30 08:41:42 +0200
committerDamien George <damien.p.george@gmail.com>2020-04-04 10:37:00 +1100
commit15f41c2dbf669e1a15ce2afb59eb29f5625d9973 (patch)
tree4c839dcaef47a54d55ee4331241bfb9fd21c8814 /ports/esp8266/modules/flashbdev.py
parente97bb58f0ea0ec94847227982c7b4a8bfb27ed34 (diff)
extmod/uasyncio: Add global exception handling methods.
This commit adds support for global exception handling in uasyncio according to the CPython error handling: https://docs.python.org/3/library/asyncio-eventloop.html#error-handling-api This allows a program to receive exceptions from detached tasks and log them to an appropriate location, instead of them being printed to the REPL. The implementation preallocates a context dictionary so in case of an exception there shouldn't be any RAM allocation. The approach here is compatible with CPython except that in CPython the exception handler is called once the task that threw an uncaught exception is freed, whereas in MicroPython the exception handler is called immediately when the exception is thrown.
Diffstat (limited to 'ports/esp8266/modules/flashbdev.py')
0 files changed, 0 insertions, 0 deletions