summaryrefslogtreecommitdiff
path: root/schall
diff options
context:
space:
mode:
Diffstat (limited to 'schall')
-rw-r--r--schall/app.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/schall/app.py b/schall/app.py
index 657d44d..b011fe1 100644
--- a/schall/app.py
+++ b/schall/app.py
@@ -92,7 +92,7 @@ def app_range(r_from=None, r_to=None, count=1000):
r_to = timeseries.time_ms()
assert count < 10000
- assert r_to - r_from <= (timeseries.C.INT_DAY * 2), "r_to - r_from = %s < %s"%(r_to-r_from, timeseries.C.INT_DAY * 2)
+ assert r_to - r_from <= (timeseries.C.INT_DAY * 5), "r_to - r_from = %s < %s"%(r_to-r_from, timeseries.C.INT_DAY * 5)
assert r_to - r_from > db.interval, "r_to - r_from = %s > "%(r_to-r_from, db.interval)
values = []
@@ -107,6 +107,7 @@ def app_range(r_from=None, r_to=None, count=1000):
if value == 0:
value = None
values.append(value)
+ gevent.sleep(0)
values.reverse()
return json.dumps(values)