import threading from .lifecyclemanager import manageLifecycle def buildThread(module): thread = threading.Thread( target=manageLifecycle, args=(module,), name=module.name ) thread.start() print("THREAD STARTED", thread) return thread