MCPcopy Create free account
hub / github.com/NGSolve/ngsolve / startConsole

Function startConsole

python/__console.py:76–94  ·  view source on GitHub ↗
(vars2)

Source from the content-addressed store, hash-verified

74 mshell.interact()
75
76def startConsole(vars2):
77 try:
78 import readline
79 import rlcompleter
80 if 'libedit' in readline.__doc__:
81 readline.parse_and_bind("bind ^I rl_complete")
82 else:
83 readline.parse_and_bind("tab: complete")
84 except:
85 try:
86 import pyreadline as readline
87 import rlcompleter
88 readline.parse_and_bind("tab:complete") # autocomplete
89 except:
90 print('readline not found')
91 shell = code.InteractiveConsole(vars2)
92 shell.push('from netgen import *')
93 shell.push('from ngsolve import *')
94 shell.interact(banner="NGS-Python console is up ...")

Callers

nothing calls this directly

Calls 1

interactMethod · 0.80

Tested by

no test coverage detected