Skip to content
Snippets Groups Projects

FIX: Ignore obligatory properties when inserting identifiables

Merged Florian Spreckelsen requested to merge f-force-identifiables into dev
All threads resolved!
@@ -544,8 +544,8 @@ carefully and if the changes are ok, click on the following link:
try:
if len(cfood.to_be_updated) > 0:
logger.info(
"Updating {} Records...".format(
len(cfood.to_be_updated)))
"Updating {} Records...".format(
len(cfood.to_be_updated)))
guard.safe_update(cfood.to_be_updated, unique=False)
except FileNotFoundError as e:
logger.info("Cannot access {}. However, it might be needed for"
@@ -610,7 +610,8 @@ carefully and if the changes are ok, click on the following link:
logger.info(
"Inserting {} Records...".format(
len(missing_identifiables)))
guard.safe_insert(missing_identifiables, unique=False)
guard.safe_insert(missing_identifiables, unique=False,
flags={"force-missing-obligatory": "ignore"})
except Exception as e:
DataModelProblems.evaluate_exception(e)
Loading