2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2025-12-19 07:47:10 +00:00

explorer added properly now

This commit is contained in:
2025-07-26 17:19:20 +02:00
parent bbb769faab
commit 751f677c44

View File

@@ -272,10 +272,11 @@ class LoadingSurvex:
# this extensive list of expo roles are now (after 24/2/2025) just comments and not legal survex code. # this extensive list of expo roles are now (after 24/2/2025) just comments and not legal survex code.
# all now irrelevant as Olly restricted the list and survex now notices this. # all now irrelevant as Olly restricted the list and survex now notices this.
# but troggle still complains, and can fail to recognise a person, if the role is not in this list:
roles = "(assistant|bitch|bodger|bolt|bolter|bolting|book|clino|comp|compass|consultant|disto|distox|distox2|" roles = "(assistant|bitch|bodger|bolt|bolter|bolting|book|clino|comp|compass|consultant|disto|distox|distox2|"
roles += "dog|dogsbody|drawing|drill|gps|helper|inst|instr|instrument|length|monkey|nagging|nail|" roles += "dog|dogsbody|drawing|drill|gps|helper|inst|instr|instrument|length|monkey|nagging|nail|"
roles += "nail_polish|nail_polish_bitch|nail_polish_monkey|nail_varnish|nail_varnish_bitch|note|notebook|" roles += "nail_polish|nail_polish_bitch|nail_polish_monkey|nail_varnish|nail_varnish_bitch|note|notebook|"
roles += "paint|photo|pic|pictures|point|polish|powerdrill|rig|rigger|rigging|shoot|sketch|slacker|" roles += "paint|photo|pic|pictures|point|polish|powerdrill|rig|rigger|rigging|shoot|sketch|slacker|explorer|"
roles += "something|station|surface|tape|topodroid|unknown|useless|varnish|waiting_patiently)" roles += "something|station|surface|tape|topodroid|unknown|useless|varnish|waiting_patiently)"
#rx_teammem = re.compile(r"(?i)" + roles + r"?(?:es|s)?\s+(.*)$") no longer legal survex ordering #rx_teammem = re.compile(r"(?i)" + roles + r"?(?:es|s)?\s+(.*)$") no longer legal survex ordering
@@ -593,7 +594,7 @@ class LoadingSurvex:
# we will have to attach them to the survexblock anyway, and then do a # we will have to attach them to the survexblock anyway, and then do a
# later check on whether they are valid when we get the date. # later check on whether they are valid when we get the date.
# big changes 24/2/2025 when Olly changed survex behaviour, and unilaterally eddited hundreds of # big changes 24/2/2025 when Olly changed survex behaviour, and unilaterally edited hundreds of
# survex files to match. So troggle has to change to match the revised, stricter syntax. # survex files to match. So troggle has to change to match the revised, stricter syntax.
if not tm: # i.e. null person inthe *team if not tm: # i.e. null person inthe *team
@@ -930,11 +931,6 @@ class LoadingSurvex:
But we need the lengths per Block, not by File. dump3d will do lengths per block. But we need the lengths per Block, not by File. dump3d will do lengths per block.
""" """
# catch bug when saving a new single survex file
if 'survexfile' not in locals():
survexfile = survexblock.survexfile
print(f"LoadSurvexLeg() UNSET 'survexfile' variable, setting to {survexblock.survexfile}")
invalid_clino = 180.0 invalid_clino = 180.0
invalid_compass = 720.0 invalid_compass = 720.0
invalid_tape = 0.0 invalid_tape = 0.0
@@ -968,7 +964,7 @@ class LoadingSurvex:
# NORMAL, so there should be 5 fields # NORMAL, so there should be 5 fields
# from the content, this is clearly reading fixedpts/gps/gps00raw.svx, but not reporting it by that name # from the content, this is clearly reading fixedpts/gps/gps00raw.svx, but not reporting it by that name
if len(ls) < 5: if len(ls) < 5:
print("! Fewer than 5 fields in NORMAL in ", survexblock.survexfile.path, survexfile, survexfile.primary) print("! Fewer than 5 fields in NORMAL in ", survexblock.survexfile.path, survexblock.survexfile, survexblock.survexfile.primary)
print(" datastar NORMAL:", self.datastar) print(" datastar NORMAL:", self.datastar)
print(f" Line (split): {ls}, comment: {comment}") print(f" Line (split): {ls}, comment: {comment}")
print(f" Line: {sline}\nsvxline: {svxline}") print(f" Line: {sline}\nsvxline: {svxline}")