Kaydet (Commit) 2284419a authored tarafından Aymeric Augustin's avatar Aymeric Augustin

[py3] Fixed cache tests.

üst f34de7dd
...@@ -167,7 +167,7 @@ class DatabaseCache(BaseDatabaseCache): ...@@ -167,7 +167,7 @@ class DatabaseCache(BaseDatabaseCache):
cursor.execute("SELECT COUNT(*) FROM %s" % table) cursor.execute("SELECT COUNT(*) FROM %s" % table)
num = cursor.fetchone()[0] num = cursor.fetchone()[0]
if num > self._max_entries: if num > self._max_entries:
cull_num = num / self._cull_frequency cull_num = num // self._cull_frequency
cursor.execute( cursor.execute(
connections[db].ops.cache_key_culling_sql() % table, connections[db].ops.cache_key_culling_sql() % table,
[cull_num]) [cull_num])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment