-
Notifications
You must be signed in to change notification settings - Fork 266
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
world_clock2_face Broken in next branch #475
Comments
Looking at the diff between the branches, this face was updated in commit bae8c65 Haven't determined yet whether this is certainly the cause. I see it also touched the sunrise and moon phase faces that I use, but I haven't seen any issue with either of those. That said, the world clock face likely relies on TZ data differently (less statically) than those two. UPDATE: This does seem to be the culprit. The world clock face relies on grabbing/calculating timezone data on the fly, and this commit removes that. I'll revert this commit and test. |
Need to look into this further... Reverting that commit fixed the timezones updating in the settings, but in display mode, the time stays locked to current local time. So there must be some other additional culprit there. Looking further... |
I found the issue. Two lines in that code need to be modified. Unfortunately, I'm AFK until Tuesday, but it's lines 188 and 293 that need changing. I would prefer adding an extra int16 in world_clock2_state that's called current_tz, and change that variable only when you change the viewed location. That way, there's fewer calculations for finding the same time zone info each time. Reviewing the other 18 complications the auto DST logic touched, it's only this face and the original world clock that had lines changed that didn't original use settings.bit.time_zone, so only those 2 faces need changing. |
Yep, I see it now, thanks! I had run out of time earlier today before getting to look at the other commits that are new in this branch and had affected this file. That new DST functionality indeed overwrote the current_zone bit. I'll try testing this again - instead of reverting that other commit, I'll try just correcting these two lines. |
Made the fixes as @voloved suggested, and it works. Two things to note, though:
Here is the git diff of the fix:
|
The new DST changes caused problems in one specific face - world_clock2. An incorrect variable was used due to a confusing name. It has been revised to fix the problems that were caused. Closes #475. Reported-by: CarpeNoctem <[email protected]> Fixed-by: David Volovskiy <[email protected]> Tested-by: CarpeNoctem <[email protected]> Tested-on-hardware-by: CarpeNoctem <[email protected]> GitHub-Pull-Request: #470 GitHub-Issue: #475
Can confirm that |
Branch: next
Tested Branch/Revision: next / be969c4 (11 Sep 2024)
Last working branch / revision: main / b69cd11 (5 Sep 2024)
Board color: GREEN
When setting offsets to enable, the offset/hour never changes, but instead stays stuck at the system's offset.
When viewing, the time never updates, but only shows the current system time as also shown by the simple clock.
The text was updated successfully, but these errors were encountered: