catch the case where all benchmarks fail (sets error)

This commit is contained in:
Colter Downing
2025-10-27 12:01:55 -07:00
parent bcecd6df40
commit d6eb498ee4
2 changed files with 4 additions and 1 deletions
+3
View File
@@ -350,6 +350,9 @@ class Backend:
total_workload = sum(br.workload for br in benchmark_requests if br.is_successful)
time_elapsed = time.time() - start
successful_responses = sum([1 for br in benchmark_requests if br.is_successful])
if successful_responses == 0:
self.backend_errored("No successful responses from benchmark")
log.debug(f"benchmark failed: {successful_responses}/{concurrent_requests} successful responses")
throughput = total_workload / time_elapsed
sum_throughput += throughput