Skip to content

Commit

Permalink
Merge ca29dc9 into f24365a
Browse files Browse the repository at this point in the history
  • Loading branch information
dantownsend committed Nov 14, 2020
2 parents f24365a + ca29dc9 commit 94553d2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
8 changes: 5 additions & 3 deletions piccolo/apps/playground/commands/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,7 @@ def run(
import IPython
except ImportError:
print(
"Install iPython using `pip install ipython==7.6.1` to use this "
"feature."
"Install iPython using `pip install ipython` to use this feature."
)
sys.exit(1)

Expand Down Expand Up @@ -176,4 +175,7 @@ def run(
print("\n")

populate()
IPython.embed()

from IPython.core.interactiveshell import _asyncio_runner

IPython.embed(using=_asyncio_runner)
7 changes: 4 additions & 3 deletions piccolo/apps/shell/commands/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ def start_ipython_shell(**tables: t.Dict[str, t.Type[Table]]):
import IPython
except ImportError:
print(
"Install iPython using `pip install ipython==7.6.1` to use this "
"feature."
"Install iPython using `pip install ipython` to use this feature."
)
sys.exit(1)

Expand All @@ -20,7 +19,9 @@ def start_ipython_shell(**tables: t.Dict[str, t.Type[Table]]):
if table_class_name not in existing_global_names:
globals()[table_class_name] = table_class

IPython.embed()
from IPython.core.interactiveshell import _asyncio_runner

IPython.embed(using=_asyncio_runner)


def run():
Expand Down

0 comments on commit 94553d2

Please sign in to comment.