Преглед на файлове

Fix All-Reduce fault-tolerance: catch Exception instead of BaseException (#424)

justheuristic преди 3 години
родител
ревизия
688b514fa6
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      hivemind/utils/asyncio.py

+ 1 - 1
hivemind/utils/asyncio.py

@@ -118,7 +118,7 @@ async def amap_in_executor(
             async for args in azip(*iterables):
                 await queue.put(loop.run_in_executor(executor, func, *args))
             await queue.put(None)
-        except BaseException as e:
+        except Exception as e:
             future = asyncio.Future()
             future.set_exception(e)
             await queue.put(future)