From 4aa7b91092fcd31348f42c7c71c86a2f16a7caf0 Mon Sep 17 00:00:00 2001 From: Ian Renton Date: Sat, 29 Nov 2025 15:01:05 +0000 Subject: [PATCH] Fix a bug where a spot with no DX lat/lon could still be marked as having "good location" --- data/spot.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/data/spot.py b/data/spot.py index b712216..f8f6471 100644 --- a/data/spot.py +++ b/data/spot.py @@ -352,9 +352,10 @@ class Spot: # DX Location is "good" if it is from a spot, or from QRZ if the callsign doesn't contain a slash, so the operator # is likely at home. - self.dx_location_good = (self.dx_location_source == "SPOT" or self.dx_location_source == "SIG REF LOOKUP" - or self.dx_location_source == "WAB/WAI GRID" - or (self.dx_location_source == "HOME QTH" and not "/" in self.dx_call)) + self.dx_location_good = self.dx_latitude and self.dx_longitude and ( + self.dx_location_source == "SPOT" or self.dx_location_source == "SIG REF LOOKUP" + or self.dx_location_source == "WAB/WAI GRID" + or (self.dx_location_source == "HOME QTH" and not "/" in self.dx_call)) # DE with no digits and APRS servers starting "T2" are not things we can look up location for if self.de_call and any(char.isdigit() for char in self.de_call) and not (self.de_call.startswith("T2") and self.source == "APRS-IS"):