We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 682a3f6 commit 3f68028Copy full SHA for 3f68028
tests/dragonfly/instance.py
@@ -453,9 +453,19 @@ def start_all(self, instances: List[DflyInstance]):
453
454
async def stop_all(self):
455
"""Stop all launched instances."""
456
+ exceptions = [] # To collect exceptions
457
for instance in self.instances:
458
await instance.close_clients()
- instance.stop()
459
+ try:
460
+ instance.stop()
461
+ except Exception as e:
462
+ exceptions.append(e) # Collect the exception
463
+ if exceptions:
464
+ first_exception = exceptions[0]
465
+ raise Exception(
466
+ f"One or more errors occurred while stopping instances. "
467
+ f"First exception: {first_exception}"
468
+ ) from first_exception
469
470
def __repr__(self) -> str:
471
return f"Factory({self.args})"
0 commit comments