graphite-project/graphite-web — pull request #166 by jbrucenet (2013-03-11 05:31:07+00:00)
Title: Fixing TypeCast errors for time based functions.

Several functions were returning floating point startTime and endTime.

As a result, urls like the following would fail.

/render/?target=keepLastValue(sin("sin"))&from=-5minutes&format=json

The resulting error stack looks like...

Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py",
line 111, in get_response
response = callback(request, *callback_args, **callback_kwargs)
File "/opt/graphite/webapp/graphite/render/views.py", line 126, in
renderView
timestamps = range(series.start, series.end, series.step)
TypeError: range() integer end argument expected, got float.