Skip to content

Commit

Permalink
🐛 Workaround for lazy-import logging issue
Browse files Browse the repository at this point in the history
  • Loading branch information
michprev committed Sep 8, 2023
1 parent a4af785 commit 2256759
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion woke/cli/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ def exit():
format="%(asctime)s %(name)s: %(message)s",
handlers=[RichHandler(show_time=False, console=console)],
level=(logging.WARNING if not debug else logging.DEBUG),
force=True, # pyright: ignore reportGeneralTypeIssues
)

ctx.ensure_object(dict)
Expand All @@ -63,7 +64,9 @@ def exit():
if platform.system() == "Windows":
asyncio.set_event_loop_policy(asyncio.WindowsProactorEventLoopPolicy())
else:
asyncio.get_event_loop_policy().set_child_watcher(ThreadedChildWatcher())
asyncio.get_event_loop_policy().set_child_watcher(
ThreadedChildWatcher() # pyright: ignore reportUnboundVariable
)

os.environ["PYTHONBREAKPOINT"] = "ipdb.set_trace"

Expand Down

0 comments on commit 2256759

Please sign in to comment.