We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3b52e01 commit 5773785Copy full SHA for 5773785
cronus/beat.py
@@ -2,6 +2,10 @@
2
Implements the beat library
3
4
Date created: 19th May 2014
5
+
6
+Modified by Vishal to skip the beatError and let beat.true loop
7
+complete the execution. If the execution time is more then set the
8
+duration_to_sleep as 0.
9
"""
10
11
import datetime
@@ -36,7 +40,8 @@ def sleep():
36
40
td = datetime.datetime.now() - loop_start_time
37
41
duration_to_sleep = loop_duration - td.total_seconds()
38
42
if duration_to_sleep < 0:
39
- raise BeatError("skipping sleep. Too much work!")
43
+ duration_to_sleep = 0; # Modified.
44
+ #raise BeatError("skipping sleep. Too much work!") Commented
45
time.sleep(duration_to_sleep)
46
47
def true():
0 commit comments