Add check if no results in __normalize method
This commit is contained in:
parent
2b71f7680e
commit
c99db3ceea
@ -71,6 +71,8 @@ class FiasFactory:
|
|||||||
|
|
||||||
sql_query = self.normalize_templ.replace("//aoid", aoid_guid)
|
sql_query = self.normalize_templ.replace("//aoid", aoid_guid)
|
||||||
rows = self.db.get_rows(sql_query, True)
|
rows = self.db.get_rows(sql_query, True)
|
||||||
|
|
||||||
|
assert len(rows), "Record with this AOID not found in DB"
|
||||||
except Exception, err:
|
except Exception, err:
|
||||||
if BasicConfig.logging:
|
if BasicConfig.logging:
|
||||||
logging.error(traceback.format_exc(err))
|
logging.error(traceback.format_exc(err))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user