##// END OF EJS Templates
Statically type OInfo....
Statically type OInfo. In view of working with #13860, some cleanup inspect to be properly typed, and using stricter datastructure. Instead of dict we now use dataclasses, this will make sure that fields type and access can be stricter and verified not only at runtime, but by mypy

File last commit:

r27288:33f5b346
r28165:0fef298a
Show More
getipython.py
24 lines | 912 B | text/x-python | PythonLexer
Brian Granger
Continuing a massive refactor of everything.
r2205 # encoding: utf-8
MinRK
add IPython.get_ipython...
r10579 """Simple function to call to get the current InteractiveShell instance
Fernando Perez
Remove 2.3 compatibility, minor cleanups.
r1414 """
#-----------------------------------------------------------------------------
MinRK
add IPython.get_ipython...
r10579 # Copyright (C) 2013 The IPython Development Team
Brian Granger
Continuing a massive refactor of everything.
r2205 #
# Distributed under the terms of the BSD License. The full license is in
# the file COPYING, distributed as part of this software.
Fernando Perez
Remove 2.3 compatibility, minor cleanups.
r1414 #-----------------------------------------------------------------------------
ville
initialization (no svn history)
r988
Brian Granger
Continuing a massive refactor of everything.
r2205 #-----------------------------------------------------------------------------
# Classes and functions
#-----------------------------------------------------------------------------
Robert Kern
ENH: Allow non-dict namespaces. This involves a change in the ipapi for setting user namespaces.
r1419
Brian Granger
ipapi.get now returns None if there are no InteractiveShells running....
r2292
MinRK
add IPython.get_ipython...
r10579 def get_ipython():
"""Get the global InteractiveShell instance.
Matthias Bussonnier
some docstring reformatting and fixing
r27288
MinRK
add IPython.get_ipython...
r10579 Returns None if no InteractiveShell instance is registered.
"""
Brian Granger
Fixing two minor bugs....
r2816 from IPython.core.interactiveshell import InteractiveShell
MinRK
add IPython.get_ipython...
r10579 if InteractiveShell.initialized():
return InteractiveShell.instance()