Skip to content
This repository has been archived by the owner on Mar 6, 2024. It is now read-only.

Commit

Permalink
Fix patching an already running Proactor loop, fixes #87
Browse files Browse the repository at this point in the history
  • Loading branch information
erdewit committed Jan 15, 2024
1 parent d5a13b0 commit c4b8289
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nest_asyncio.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ def _check_running(self):
cls._run_once = _run_once
cls._check_running = _check_running
cls._check_runnung = _check_running # typo in Python 3.7 source
cls._num_runs_pending = 0
cls._num_runs_pending = 1 if loop.is_running() else 0
cls._is_proactorloop = (
os.name == 'nt' and issubclass(cls, asyncio.ProactorEventLoop))
if sys.version_info < (3, 7, 0):
Expand Down

0 comments on commit c4b8289

Please sign in to comment.