Merge pull request #15179 from nextchamp-saqib/fix-sql-mask-error

fix: IndexError while handling sql timeout error
This commit is contained in:
mergify[bot] 2021-12-03 13:27:19 +00:00 committed by GitHub
commit 5172e9e5d2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -171,10 +171,10 @@ class Database(object):
frappe.errprint(query)
elif self.is_deadlocked(e):
raise frappe.QueryDeadlockError
raise frappe.QueryDeadlockError(e)
elif self.is_timedout(e):
raise frappe.QueryTimeoutError
raise frappe.QueryTimeoutError(e)
if ignore_ddl and (self.is_missing_column(e) or self.is_missing_table(e) or self.cant_drop_field_or_key(e)):
pass