1👍
✅
Instead of using invoke.cli.parse
should use invoke.cli.dispath
like:
invoke.cli.dispatch(['-r', os.path.dirname(__file__), 'setup'])
Source:stackexchange.com