def open_python(self, message, namespace):
<EOL>from code import InteractiveConsole<EOL>import readline<EOL>import rlcompleter<EOL>readline.set_completer(rlcompleter.Completer(namespace).complete)<EOL>readline.parse_and_bind('<STR_LIT>')<EOL>console = InteractiveConsole(namespace)<EOL>console.interact(message)<EOL>
Open interactive python console