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.
2 parents 59217e7 + 1fef416 commit 32a94efCopy full SHA for 32a94ef
reframe/frontend/executors/policies.py
@@ -6,6 +6,7 @@
6
import contextlib
7
import functools
8
import itertools
9
+import math
10
import sys
11
import time
12
@@ -63,9 +64,10 @@ def running_tasks(self, num_tasks):
63
64
def snooze(self):
65
t_elapsed = time.time() - self._t_init
66
self._num_polls += 1
67
+ poll_rate = self._num_polls / t_elapsed if t_elapsed else math.inf
68
getlogger().debug2(
69
f'Poll rate control: sleeping for {self._sleep_duration}s '
- f'(current poll rate: {self._num_polls/t_elapsed} polls/s)'
70
+ f'(current poll rate: {poll_rate} polls/s)'
71
)
72
time.sleep(self._sleep_duration)
73
0 commit comments