Skip to content

Commit

Permalink
Only close scheduler in SpecCluster if it exists (#6888)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrocklin authored Aug 17, 2022
1 parent 3647cfe commit 1d0701b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion distributed/deploy/spec.py
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ async def _close(self):
else:
logger.warning("Cluster closed without starting up")

await self.scheduler.close()
if self.scheduler:
await self.scheduler.close()
for w in self._created:
assert w.status in {
Status.closing,
Expand Down

0 comments on commit 1d0701b

Please sign in to comment.