From 622a4a902d98eed3bfd257811db142904e0e5ca3 Mon Sep 17 00:00:00 2001 From: Modrzew Date: Wed, 10 Aug 2016 16:36:47 +0200 Subject: [PATCH] Revert two database changes - no more pool_size for create_engine It didn't work out of the box for SQLite. Moreover, there's a different solution that will be implemented soon. - no more grouping by id in get_forts This made query return all fort sightings, instead of only the recent ones. --- db.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/db.py b/db.py index cdb9c361bb..0519beea20 100644 --- a/db.py +++ b/db.py @@ -24,7 +24,7 @@ class Team(enum.Enum): def get_engine(): - return create_engine(DB_ENGINE,pool_size=config.GRID[0]*config.GRID[1]+5) + return create_engine(DB_ENGINE) def get_engine_name(session): @@ -267,7 +267,7 @@ def get_forts(session): FROM fort_sightings fs JOIN forts f ON f.id=fs.fort_id ORDER BY fs.last_modified DESC - ) t GROUP BY fort_id, id + ) t GROUP BY fort_id ''') return query.fetchall()