Selaa lähdekoodia

HUE-9188 [notebook] Connection leakage in sqlalchemy connector (#1059)

Romain Rigaux 5 vuotta sitten
vanhempi
commit
ac887d2c90
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      desktop/libs/notebook/src/notebook/connectors/sql_alchemy.py

+ 1 - 1
desktop/libs/notebook/src/notebook/connectors/sql_alchemy.py

@@ -266,7 +266,7 @@ class SqlAlchemyApi(Api):
 
     try:
       guid = snippet['result']['handle']['guid']
-      connection = CONNECTION_CACHE.get('guid')
+      connection = CONNECTION_CACHE.get(guid)
       if connection:
         connection['connection'].close()
         del CONNECTION_CACHE[guid]