diff options
author | Philip Sargent <philip.sargent@gmail.com> | 2023-10-16 13:35:36 +0300 |
---|---|---|
committer | Philip Sargent <philip.sargent@gmail.com> | 2023-10-16 13:35:36 +0300 |
commit | 6b948293152da07d2455e34beeb3bda5e918a062 (patch) | |
tree | fd6d5b55e5e6cc6201e41b099e7102c18a59a329 /parsers/caves.py | |
parent | d88ae2f78c9c30f71ed65f1c987bd18d3d6e1e29 (diff) | |
download | troggle-6b948293152da07d2455e34beeb3bda5e918a062.tar.gz troggle-6b948293152da07d2455e34beeb3bda5e918a062.tar.bz2 troggle-6b948293152da07d2455e34beeb3bda5e918a062.zip |
bug in pending caves parsing
Diffstat (limited to 'parsers/caves.py')
-rw-r--r-- | parsers/caves.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/parsers/caves.py b/parsers/caves.py index d69273f..288719d 100644 --- a/parsers/caves.py +++ b/parsers/caves.py @@ -847,9 +847,11 @@ def readcaves(): with open(fpending, "r") as fo: cids = fo.readlines() for cid in cids: - pcaveid = cid.strip().rstrip("\n") - if pcaveid !="": - pending.add(pcaveid) + pcaveid = cid.split(";", 1)[0] # split on ";" and take the first bit + pcaveid = pcaveid.strip().rstrip("\n") + if pcaveid =="": + continue + pending.add(pcaveid) with transaction.atomic(): print(" - Deleting Caves and Entrances") |