fix backcall
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
from __future__ import print_function
|
||||
|
||||
# the name of the package
|
||||
name = 'ipykernel'
|
||||
name = 'yap_kernel'
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Minimal Python version sanity check
|
||||
|
@@ -13,7 +13,7 @@ events and the arguments which will be passed to them.
|
||||
This API is experimental in yap_ipython 2.0, and may be revised in future versions.
|
||||
"""
|
||||
|
||||
from yap_ipython.core.backcall import callback_prototype
|
||||
from backcall import callback_prototype
|
||||
|
||||
|
||||
class EventManager(object):
|
||||
|
@@ -727,7 +727,6 @@ class YAPRun:
|
||||
self.result.result = False
|
||||
has_raised = False
|
||||
try:
|
||||
builtin_mod.input = self.shell.sys_raw_input
|
||||
self.yapeng.mgoal(streams(True),"user", True)
|
||||
if cell.strip('\n \t'):
|
||||
#create a Trace object, telling it what to ignore, and whether to
|
||||
|
@@ -166,14 +166,14 @@ class YAPKernel(KernelBase):
|
||||
"""
|
||||
self._allow_stdin = allow_stdin
|
||||
|
||||
# if PY3:
|
||||
# self._sys_raw_input = builtin_mod.input
|
||||
# builtin_mod.input = self.raw_input
|
||||
# else:
|
||||
# self._sys_raw_input = builtin_mod.raw_input
|
||||
# self._sys_eval_input = builtin_mod.input
|
||||
# builtin_mod.raw_input = self.raw_input
|
||||
# builtin_mod.input = lambda prompt='': eval(self.raw_input(prompt))
|
||||
if PY3:
|
||||
self._sys_raw_input = builtin_mod.input
|
||||
builtin_mod.input = self.raw_input
|
||||
else:
|
||||
self._sys_raw_input = builtin_mod.raw_input
|
||||
self._sys_eval_input = builtin_mod.input
|
||||
builtin_mod.raw_input = self.raw_input
|
||||
builtin_mod.input = lambda prompt='': eval(self._sys_input(prompt))
|
||||
self._save_getpass = getpass.getpass
|
||||
getpass.getpass = self.getpass
|
||||
|
||||
|
Reference in New Issue
Block a user