"Another one might have committed a record with the same key(s).".format(repr(e))
)
else:
raise
except SQLAlchemyError as e:
session.rollback()
message = (
"An exception is raised during the commit. "
After Change
"e.g. exceeding max length. "
"(The actual exception is as follows: {})".format(repr(e))
)
raise optuna.exceptions.StorageInternalError(message).with_traceback(sys.exc_info()[2])
except SQLAlchemyError as e:
session.rollback()
message = (