Don't gather check_parent_task on Windows, since it's undefined. (#13700)

This commit is contained in:
Clark Zinzow 2021-01-27 10:19:58 -07:00 committed by GitHub
parent c5b645e3da
commit 2d34e95c93
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -185,8 +185,11 @@ class DashboardAgent(object):
agent_port=self.grpc_port,
agent_ip_address=self.ip))
await asyncio.gather(check_parent_task,
*(m.run(self.server) for m in modules))
tasks = [m.run(self.server) for m in modules]
if sys.platform not in ["win32", "cygwin"]:
tasks.append(check_parent_task)
await asyncio.gather(*tasks)
await self.server.wait_for_termination()
# Wait for finish signal.
await runner.cleanup()