Skip to content

Commit

Permalink
Don't run kernel if subapp
Browse files Browse the repository at this point in the history
  • Loading branch information
davidbrochart committed Dec 17, 2024
1 parent 28a72bd commit 007d12f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions ipykernel/kernelapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -734,11 +734,12 @@ def start(self) -> None:
"""Start the application."""
if self.subapp is not None:
self.subapp.start()
return
if self.poller is not None:
self.poller.start()
if self.kernel is not None:
backend = "trio" if self.trio_loop else "asyncio"
run(self.main, backend=backend)
backend = "trio" if self.trio_loop else "asyncio"
run(self.main, backend=backend)
return

async def _wait_to_enter_eventloop(self):
await self.kernel._eventloop_set.wait()
Expand Down

0 comments on commit 007d12f

Please sign in to comment.