Skip to content

Commit

Permalink
Make sure there is no key error when removing the PWD entry from the …
Browse files Browse the repository at this point in the history
…cstr dict
  • Loading branch information
kummerer94 committed Mar 31, 2020
1 parent a72c5c7 commit a31af19
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sql_server/pyodbc/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ def get_new_connection(self, conn_params):
if auth:
cstr_parts['Authentication'] = auth
if auth == 'ActiveDirectoryInteractive':
cstr_parts.pop('PWD')
cstr_parts.pop('PWD', '')
cstr_parts['Trusted_Connection'] = 'no'

connstr = encode_connection_string(cstr_parts)
Expand Down

0 comments on commit a31af19

Please sign in to comment.