Hourly windBearing can be less than 0
trevorturk opened this issue · 3 comments
Describe the bug
Hourly windBearing can be less than 0
Expected behavior
Hourly windBearing should be between 0-360
Actual behavior
windBearing = -18.0 for 41.883,-87.632 at 2024-11-08 19:00:00 -0600
API Endpoint
Production
Location
41.883,-87.632
Other details
No response
Troubleshooting steps
- I have searched this repository and Home Assistant Repository to see if the issue has already been reported.
- I have read through the API documentation before opening this issue.
- I have not included my API key anywhere in my issue.
- I have written an informative title.
Looks like windBearing
doesn't keep its value between 0 and 360 degrees. The fix is to just use modulo 360 to keep the values between 0 and 360. Will ping @alexander0042 to fix this in the API but for the time being you can add this on your end.
Sorry I didn't reply to this, was caught up getting the self hosting/ open-source stuff together (so next time I'll be able to point to the exact line where the bug is!). I've added that mod statement in for both the hourly/daily and currently blocks, so should be fixed in 2.4!
🥇 thank you!