Fix migration failing when existing data has duplicates (#88712)
This commit is contained in:
parent
e69091c6db
commit
69a3738bdb
2 changed files with 26 additions and 5 deletions
|
@ -125,7 +125,7 @@ def session_scope(
|
|||
need_rollback = True
|
||||
session.commit()
|
||||
except Exception as err: # pylint: disable=broad-except
|
||||
_LOGGER.error("Error executing query: %s", err)
|
||||
_LOGGER.error("Error executing query: %s", err, exc_info=True)
|
||||
if need_rollback:
|
||||
session.rollback()
|
||||
if not exception_filter or not exception_filter(err):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue