HourWeather timezone offset?

I'm playing with Swift Charts and WeatherKit. I have a simple chart where I plot temperate values for the current day. When I log out the date values, they look right, but when I actually look at the data, it looks like it's missing a timezone offset. I'm looking at a location that is UTC-7.

The data is showing the lowest temperature of the day occurring at 1:30pm and the peak temp occurring at midnight.

I feel that I need to shift all the values coming from weatherkit by my timezone offset.

I just looked into this a bit more by looking at the HourWeather.symbolName data. It looks like I do need to apply a timezone offset to the dates provided by weatherkit. If I don't, it's showing as night up until 1pm.

How are you formatting those time strings? You would need to use a date formatter with the time zone set correctly. WeatherKit uses the good old Date type and (in my testing here) they are correct, whether I view them in the debugger or print them using a date formatter set to my time zone.

Scratch that. Now I’m going with the theory (commented in your other thread) that your chart is correct but actually showing weather data from somewhere else. If the longitude were flipped from 119ºW to 119ºE then it would designate a place with the same season and the same daily sun cycle, just shifted about 8 hours behind. This could explain all the weird results you’re seeing.

HourWeather timezone offset?
 
 
Q