'float' object has no attribute 'iteritems'

#1

Hi,
When update from 4.0 to 6.0, execute a query in client, " Error running query: unknown error occurred. Please try again later."
Check log out:
[2019-03-14 02:17:29,707][PID:15423][ERROR][ForkPoolWorker-10] Task redash.tasks.execute_query[13c90ea8-c8ed-49a5-8ded-d5b3ead5b12f] raised unexpected: AttributeError("‘float’ object has no attribute ‘iteritems’",)
Traceback (most recent call last):
File “/usr/local/lib/python2.7/dist-packages/celery/app/trace.py”, line 382, in trace_task
R = retval = fun(*args, **kwargs)
File “/opt/redash/redash.6.0.0.b8536/redash/worker.py”, line 71, in call
return TaskBase.call(self, *args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/celery/app/trace.py”, line 641, in protected_call
return self.run(*args, **kwargs)
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 533, in execute_query
scheduled_query).run()
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 445, in run
self.tracker.update(started_at=time.time(), state=‘started’)
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 71, in update
self.save()
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 62, in save
connection.zadd(self._get_list(), time.time(), key_name)
File “/usr/local/lib/python2.7/dist-packages/redis/client.py”, line 2320, in zadd
for pair in iteritems(mapping):
File “/usr/local/lib/python2.7/dist-packages/redis/_compat.py”, line 81, in iteritems
return x.iteritems()
AttributeError: ‘float’ object has no attribute ‘iteritems’

2 Likes
#2

Same here after upgrade from V5 to V6:

2019-03-19 20:41:17,395][PID:22124][ERROR][ForkPoolWorker-20] Task redash.tasks.refresh_queries[3b5f2103-4c9b-4827-bd7a-82395453fe7a] raised unexpected: AttributeError("‘float’ object has no attribute ‘iteritems’",)
Traceback (most recent call last):
File “/usr/local/lib/python2.7/dist-packages/celery/app/trace.py”, line 382, in trace_task
R = retval = fun(*args, **kwargs)
File “/opt/redash/redash.6.0.0.b8536/redash/worker.py”, line 71, in call
return TaskBase.call(self, *args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/celery/app/trace.py”, line 641, in protected_call
return self.run(*args, **kwargs)
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 293, in refresh_queries
metadata={‘Query ID’: query.id, ‘Username’: ‘Scheduled’})
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 250, in enqueue_query
tracker.save(connection=pipe)
File “/opt/redash/redash.6.0.0.b8536/redash/tasks/queries.py”, line 62, in save
connection.zadd(self._get_list(), time.time(), key_name)
File “/usr/local/lib/python2.7/dist-packages/redis/client.py”, line 2320, in zadd
for pair in iteritems(mapping):
File “/usr/local/lib/python2.7/dist-packages/redis/_compat.py”, line 81, in iteritems
return x.iteritems()
AttributeError: ‘float’ object has no attribute ‘iteritems’

#3

i also get the error