From 5a191ee554488ff8cf3668f011440edecf671e49 Mon Sep 17 00:00:00 2001 From: Philip Sargent Date: Fri, 8 Sep 2023 19:51:04 +0300 Subject: Big refactor of cave lookuo & creation. Works. --- parsers/caves.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'parsers/caves.py') diff --git a/parsers/caves.py b/parsers/caves.py index c16a577..982fb40 100644 --- a/parsers/caves.py +++ b/parsers/caves.py @@ -133,6 +133,7 @@ def get_area(areanum): def create_new_cave(svxpath): """This is called only when a new survex file is edited online which has a path on the :loser: repo which is not recognised as a known cave. + ALSO called by survex parser when it finds a cave it doesn't recognise """ # e.g. svxpath = "caves-1623/666/antig" print(f"Create new cave at {svxpath}") @@ -171,7 +172,8 @@ def create_new_cave(svxpath): print(message) raise - # we know what the survex file is, we don't need to use the guess + # we know what the survex file is, we don't need to use the guess. + # But this sets the survex file on he cave from the first one we find, not necessarily the best survex file for this cave cave.survex_file=survex_file cave.save() return cave -- cgit v1.2.3