Improve some activity detection

This commit is contained in:
Ian Renton
2026-09-20 10:32:53 +01:00
parent 190c9f6cef
commit 6f96e0ede1
9 changed files with 20 additions and 20 deletions
+5 -5
View File
@@ -10,7 +10,7 @@ ACTIVITIES: dict[ActivityName, Activity] = {
refs_globally_unique=False,
# No sensible way to determine *which* contest, but if we set comment_names=["CONTEST"] then at least
# any spots with "contest" in the comment will get allocated to this activity.
comment_names=["CONTEST"],
comment_names=["CONTEST", "TEST"],
icon="fa-trophy",
alerts_possible=True,
),
@@ -150,9 +150,9 @@ ACTIVITIES: dict[ActivityName, Activity] = {
description="Islands on the Air",
sig_type=ActivityType.ADVENTURE,
has_refs=True,
refs_globally_unique=False,
refs_globally_unique=True,
ref_type=ActivityRefType.ISLAND,
ref_regex=r"[A-Z]{2}\-\d{3}",
ref_regex=r"(?:AF|AN|AS|EU|NA|OC|SA)\-\d{3}",
comment_names=["IOTA"],
icon="fa-book-atlas",
),
@@ -163,7 +163,7 @@ ACTIVITIES: dict[ActivityName, Activity] = {
has_refs=True,
refs_globally_unique=False,
ref_type=ActivityRefType.ISLAND,
ref_regex=r"(([A-Z]{2}\-\d{3})|([A-Z0-9]{1,3}\/[A-Z]{2}\-\d{3}))",
ref_regex=r"(?:(?:[A-Z]{2}\-\d{3})|(?:[A-Z0-9]{1,3}\/[A-Z]{2}\-\d{3}))",
comment_names=[],
icon="fa-person-hiking",
),
@@ -386,7 +386,7 @@ ACTIVITIES: dict[ActivityName, Activity] = {
# FEA references are technically [DE]\-\d{4}(\.\d)? but spotters always seem to miss out the D- or E-
# prefix and just use FEA-1234 or FEA 1234, so allow for that. The FEA activity ref data provider adds both
# forms to the database.
ref_regex=r"([DE]|FEA)[\- ]\d{4}(\.\d)?",
ref_regex=r"(?:[DE]|FEA)[\- ]\d{4}(?:\.\d)?",
comment_names=["FEA"],
icon="fa-house-flood-water",
region_flag="🇪🇸",