weather: show symbols for the next 12 hours

This commit is contained in:
Vincent Bernat 2024-05-13 09:40:39 +02:00
parent 4f44050fe7
commit dd3e05604e

View file

@ -179,8 +179,9 @@ if __name__ == "__main__":
"{}°C".format( "{}°C".format(
round(weather[0]["data"]["instant"]["details"]["air_temperature"]) round(weather[0]["data"]["instant"]["details"]["air_temperature"])
), ),
# Forecast: use the symbol for the next 6 hours # Forecast: use the symbol for the next 6 hours and the period after
format_icon(weather[0]["data"]["next_6_hours"]["summary"]["symbol_code"]), format_icon(weather[0]["data"]["next_6_hours"]["summary"]["symbol_code"])
+ format_icon(weather[6]["data"]["next_6_hours"]["summary"]["symbol_code"]),
# And the temperature range computed for the next 24 hours # And the temperature range computed for the next 24 hours
"{}—{}°C".format(round(mintemp), round(maxtemp)), "{}—{}°C".format(round(mintemp), round(maxtemp)),
] ]