We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 18cb4ff commit 3191a08Copy full SHA for 3191a08
scrapy/utils/console.py
@@ -11,7 +11,10 @@ def start_python_console(namespace=None, noipython=False):
11
if noipython:
12
raise ImportError
13
import IPython
14
- shell = IPython.Shell.IPShellEmbed(argv=[], user_ns=namespace)
+ try:
15
+ shell = IPython.embed(user_ns=namespace)
16
+ except AttributeError:
17
+ shell = IPython.Shell.IPShellEmbed(argv=[], user_ns=namespace)
18
shell()
19
except ImportError:
20
import code
0 commit comments