##// END OF EJS Templates
Fix demo.py so it uses the new get_ipython() call for global instance
Fernando Perez -
Show More
@@ -244,11 +244,12 b' class Demo(object):'
244 # it ensures that things like color scheme and the like are always in
244 # it ensures that things like color scheme and the like are always in
245 # sync with the ipython mode being used. This class is only meant to
245 # sync with the ipython mode being used. This class is only meant to
246 # be used inside ipython anyways, so it's OK.
246 # be used inside ipython anyways, so it's OK.
247 self.ip_ns = __IPYTHON__.user_ns
247 ip = get_ipython() # this is in builtins whenever IPython is running
248 self.ip_colorize = __IPYTHON__.pycolorize
248 self.ip_ns = ip.user_ns
249 self.ip_showtb = __IPYTHON__.showtraceback
249 self.ip_colorize = ip.pycolorize
250 self.ip_runlines = __IPYTHON__.runlines
250 self.ip_showtb = ip.showtraceback
251 self.shell = __IPYTHON__
251 self.ip_runlines = ip.runlines
252 self.shell = ip
252
253
253 # load user data and initialize data structures
254 # load user data and initialize data structures
254 self.reload()
255 self.reload()
General Comments 0
You need to be logged in to leave comments. Login now