]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Fix UnboundLocalError in mssql during isolation level grab
authorMike Bayer <mike_mp@zzzcomputing.com>
Mon, 18 Jun 2018 14:12:56 +0000 (17:12 +0300)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 25 Jun 2018 22:35:55 +0000 (18:35 -0400)
commitd404111ad458a22bc2e398931e735912d9fcb079
treec662ab26d34910695547a17f22c50549675f8191
parentecd84ef096c320b3fade5ba4882d17e627241cb6
Fix UnboundLocalError in mssql during isolation level grab

Fixed issue within the SQL Server dialect under Python 3 where when running
against a non-standard SQL server database that does not contain either the
"sys.dm_exec_sessions" or "sys.dm_pdw_nodes_exec_sessions" views, leading
to a failure to fetch the isolation level, the error raise would fail due
to an UnboundLocalError.

Fixes: #4273
Co-authored-by: wikiped <wikiped@yandex.ru>
Change-Id: I39877c1f65f9cf8602fb1dceaf03072357759564
(cherry picked from commit e2913f65c4e5720394105584c69e7b9e8c2d373c)
doc/build/changelog/unreleased_12/4273.rst [new file with mode: 0644]
lib/sqlalchemy/dialects/mssql/base.py
test/dialect/mssql/test_engine.py