@task('Starting Modules')
def start(module='*', env='development'):
	""" Start [module] """

	os.environ['APP_ENV'] = env

	for module, path in all_modules(module):
		try:
			cmd = "PYTHONPATH=. %s %s &>> logs/%s.log" % (python(), path, module)
			shell("echo '%s' | at now" % cmd, exception=PyscaleError)
		except PyscaleError as e:
			msg = str(e).strip('\n')
			msg = ' '.join(msg.split('\n'))

			puts(fore.cyan("%-10s" % module) + "(%s) scheduled" % msg)
dataset/ETHPy150Open alexcepoi/pyscale/pyscale/tools/tasks.py/start/original