flynt pass to provide consistency to string formatters and concatenation

This commit is contained in:
Ian Renton
2026-08-15 07:55:32 +01:00
parent bff5b79f8f
commit 7391c28cd0
72 changed files with 184 additions and 193 deletions
+2 -2
View File
@@ -72,11 +72,11 @@ class HamQSL(HTTPSolarConditionsProvider):
tz_abbr = updated_str.split()[-1]
timezone = dateutil_tz.gettz(tz_abbr)
if timezone is None:
raise ValueError("Unknown timezone abbreviation: " + tz_abbr)
raise ValueError(f"Unknown timezone abbreviation: {tz_abbr}")
dt = dateutil_parser.parse(updated_str, tzinfos={tz_abbr: timezone})
updated = dt.astimezone(pytz.UTC).timestamp()
except (ValueError, IndexError):
logging.warning("HamQSL solar conditions API returned unrecognised timestamp format: " + updated_str)
logging.warning(f"HamQSL solar conditions API returned unrecognised timestamp format: {updated_str}")
# Return the data ready to be put into the solar conditions object.
return {