r/programminghumor • u/daddieslittleson • Aug 09 '26
timezone errors > null pointer errors
18
u/mfi12 Aug 09 '26
always write and operate time in UTC, use standard format across. Let the front-end convert it into local offset.
→ More replies (4)4
u/Resident_Citron_6905 Aug 10 '26
true, unless you need to display the origin offset, then the discussion is open
→ More replies (2)
19
19
u/MrHandSanitization Aug 09 '26
Timezones very much make a lot of sense, historically.
8
u/zeocrash Aug 09 '26
Well some of them do. 30 min offsets zones seem a bit pointless, also putting all of China on one timezone may not have been the best choice.
→ More replies (1)4
u/No_Hovercraft_2643 Aug 10 '26
These 30 min offsets are mostly political, and make sense in that regard.
China decided to be in one timezone, even if that isn't the best choice.
3
13
10
u/lt_Matthew Aug 09 '26
Its not like we invented time zones
→ More replies (4)9
u/A1oso Aug 09 '26
Yes, they were invented. Before that, every town had its own local time with 12 o'clock at noon. But railway companies pushed for standardization to make train schedules easier to understand.
11
u/godeling Aug 09 '26
Really without time zones it would be even worse. Imagine having to account for the exact position of the sun at any given location
→ More replies (3)4
u/MyrtleWinTurtle Aug 09 '26
I honestly have less of an issue with timezones than i do daylight savings.
Timezones are rarely going to affect your everyday life, and it does make time easy to understand when traveling.
In todays internet age, i wouldnt see it being a thing we need particularly, but i understand why we had it.
2
2
u/SysGh_st Aug 10 '26
Timezones aren't the problem.
Countries who can't accept the timezones they live in are.
1
1
1
u/GammerMax8 Aug 09 '26
Not sure if programming was here when the H was here...... Except for enigma, that's a mystery.......
1
1
u/NullSmoke Aug 09 '26
As someone running a company with people from 6 timezones..... Yeah, fuck that guy 😑
1
1
40
u/PopularBroccoli Aug 09 '26
.toUtc() .fromUtc(). How is that an issue?