mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2024-11-22 15:21:52 +00:00
tidy up more 'url' fossils
This commit is contained in:
parent
0c1601e1b0
commit
2761fb5867
@ -93,16 +93,6 @@ def set_dummy_entrance(id, slug, cave, msg="DUMMY"):
|
|||||||
message = f" - Note: Missing Entrance for entrance '{id}' on cave '{cave}' - Is this a problem?"
|
message = f" - Note: Missing Entrance for entrance '{id}' on cave '{cave}' - Is this a problem?"
|
||||||
DataIssue.objects.create(parser="entrances", message=message, url=f"{cave.url}")
|
DataIssue.objects.create(parser="entrances", message=message, url=f"{cave.url}")
|
||||||
|
|
||||||
# try:
|
|
||||||
# entrance = dummy_entrance(id, slug, msg="DUMMY")
|
|
||||||
# entrances_xslug[slug] = entrance
|
|
||||||
# CaveAndEntrance.objects.update_or_create(cave=cave, entranceletter="", entrance=entrance)
|
|
||||||
# pass
|
|
||||||
# except:
|
|
||||||
# message = f' ! Entrance Dummy setting failure, slug:"{slug}" cave id :"{id}" '
|
|
||||||
# DataIssue.objects.create(parser="entrances", message=message, url=f"{cave.url}")
|
|
||||||
# print(message)
|
|
||||||
|
|
||||||
def add_cave_to_pending_list(id, wallet, message):
|
def add_cave_to_pending_list(id, wallet, message):
|
||||||
"""(id, f"Wallet {wallet} - Could not find id <{id}>")
|
"""(id, f"Wallet {wallet} - Could not find id <{id}>")
|
||||||
"""
|
"""
|
||||||
@ -526,7 +516,6 @@ def read_entrance(filename, ent=None):
|
|||||||
photo = getXMLmax1("photo")
|
photo = getXMLmax1("photo")
|
||||||
tag_station = getXMLmax1("tag_station")
|
tag_station = getXMLmax1("tag_station")
|
||||||
underground_description = getXMLmax1("underground_description")
|
underground_description = getXMLmax1("underground_description")
|
||||||
url = getXMLmax1("url")
|
|
||||||
|
|
||||||
if not ent:
|
if not ent:
|
||||||
ent, state = Entrance.objects.update_or_create(slug=slug)
|
ent, state = Entrance.objects.update_or_create(slug=slug)
|
||||||
@ -759,16 +748,9 @@ def read_cave(filename, cave=None):
|
|||||||
extent = getXMLmax1("extent")
|
extent = getXMLmax1("extent")
|
||||||
survex_file = getXMLmax1("survex_file")
|
survex_file = getXMLmax1("survex_file")
|
||||||
description_file = getXMLmax1("description_file")
|
description_file = getXMLmax1("description_file")
|
||||||
# url = getXMLmax1("url")
|
|
||||||
|
|
||||||
contextguess = f"/{slug[0:4]}/{slug}_cave_edit/" # guess as we havent read areacode yet
|
contextguess = f"/{slug[0:4]}/{slug}_cave_edit/" # guess as we havent read areacode yet
|
||||||
|
|
||||||
# urltest = Cave.objects.filter(url=url)
|
|
||||||
# if urltest:
|
|
||||||
# message = f" ! - URL duplicate {urltest[0]} already exists with proposed url {url}. Should not create new cave {slug} from {filename}"
|
|
||||||
# DataIssue.objects.create(parser="caves", message=message, url=contextguess)
|
|
||||||
# print(message)
|
|
||||||
|
|
||||||
manual_edit = True
|
manual_edit = True
|
||||||
if not cave:
|
if not cave:
|
||||||
# we are parsing using databaseReset.py not an online edit
|
# we are parsing using databaseReset.py not an online edit
|
||||||
|
Loading…
Reference in New Issue
Block a user