def main(namespace):
	# parse args
	command = ' '.join(sys.argv[1:])

	if not command:
		# console (interactive)
		try: reinit(namespace)
		except __HOLE__:
			pass

		# ignore Ctrl-C (interferes with gevent)
		signal.signal(signal.SIGINT, lambda signum, frame: None)
	else:
		# call (non-interactive)
		reinit(namespace, info=False)

		console = code.InteractiveConsole(locals())
		console.runsource(command)
dataset/ETHPy150Open alexcepoi/pyscale/pyscale/tools/console.py/main