Skip to content
Snippets Groups Projects
Commit 49806aab authored by Henrik tom Wörden's avatar Henrik tom Wörden
Browse files

sty

parent 167b96a2
No related branches found
No related tags found
2 merge requests!178FIX: #96 Better error output for crawl.py script.,!167Sync Graph
Pipeline #50940 failed
......@@ -502,7 +502,7 @@ class Crawler(object):
def _get_property_id_for_datatype(rtname: str, name: str):
return cached_get_entity_by(
query=f"FIND Entity '{escape_squoted_text(rtname)}' "
f"with name='{escape_squoted_text(name)}'").id
f"with name='{escape_squoted_text(name)}'").id
@staticmethod
def replace_name_with_referenced_entity_id(prop: db.Property):
......@@ -683,8 +683,10 @@ class Crawler(object):
if len(ins_problems) > 0 or len(upd_problems) > 0:
raise ForbiddenTransaction(
"One or more Records that have a parent which is excluded from inserts or updates."
f"\nRecords excluded from inserts have the following RecordTypes:\n{[el.parents[0].name for el in ins_problems]}"
f"\nRecords excluded from updates have the following RecordTypes:\n{[el.parents[0].name for el in upd_problems]}"
f"\nRecords excluded from inserts have the following RecordTypes:\n"
f"{[el.parents[0].name for el in ins_problems]}"
f"\nRecords excluded from updates have the following RecordTypes:\n"
f"{[el.parents[0].name for el in upd_problems]}"
)
logger.info(f"Going to insert {len(to_be_inserted)} Entities and update "
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment