From e9d4749f4470aee294f1351baa9422173a2a62c8 Mon Sep 17 00:00:00 2001 From: Maxime Beauchemin Date: Fri, 21 Oct 2016 13:35:21 -0700 Subject: [PATCH] [hotfix] sqllab presto --- caravel/db_engine_specs.py | 2 +- caravel/sql_lab.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/caravel/db_engine_specs.py b/caravel/db_engine_specs.py index dfb86905f366f..319700ea5cf73 100644 --- a/caravel/db_engine_specs.py +++ b/caravel/db_engine_specs.py @@ -55,7 +55,7 @@ def convert_dttm(cls, target_type, dttm): return "'{}'".format(dttm.strftime('%Y-%m-%d %H:%M:%S')) @classmethod - def handle_cursor(cls, cursor, query): + def handle_cursor(cls, cursor, query, session): """Handle a live cursor between the execute and fetchall calls The flow works without this method doing anything, but it allows diff --git a/caravel/sql_lab.py b/caravel/sql_lab.py index 23f3eb09a1060..914f0c2d61f09 100644 --- a/caravel/sql_lab.py +++ b/caravel/sql_lab.py @@ -98,7 +98,7 @@ def handle_error(msg): cursor = result_proxy.cursor query.status = QueryStatus.RUNNING session.flush() - db_engine_spec.handle_cursor(cursor, query) + db_engine_spec.handle_cursor(cursor, query, session) cdf = None if result_proxy.cursor: