 the DST and non-DST versions label themselves as such, the
> representation used to track time must distinguish whether DST is active or
> not to display the correct local time. Really, when I say store local time +
> timezone, I mean local time plus identifier that gets you to the same unique
> timezone representation in your medium (python, in this case).

I guess that's my point: the IANA identifier is a well-known way to serialize
a TZ, but doesn't include DST flags because they're not relevant. I think if
you wanted to store something like a Python tzinfo object, the easiest way is
just storing (local time, offset from UTC); (maybe (local time, offset from
UTC, IANA TZ ID), if you want to keep the TZ)

tzinfo's don't really have a defining quality in Python, I've found. You can
end up — depending on libraries used — with two tzinfos that both conceptually
are "UTC", but don't compare equal…

Now that I've thought about it again, I'm not entirely sure that the DST flag
+ TZ name by itself is sufficient, mostly in the case of a TZ deciding to
change their offset.

> just always convert to UTC and store that. It changes the problem from one
> of data fidelity to display

The right thing to do, and for the right reasons.

------
toyg
Terrible PEP, I hope it gets rejected. One-off flags like this are hacks that
shouldn't be in stdlib. It simply stinks, in an area (time handling) where the
stdlib does not really smell like roses already.

Dealing with time adjustments is the OS's job, not userland. If your job has
to be scheduled exactly and cannot rely on the OS, and you refuse to deal with
UTC, it's your own damn fault and you can always just use a long-running
process with timers.

~~~
bliti
I agree. It's library baggage.

------
lifeisstillgood
So :

Time in UK is currently UTC +1 (BST) At 2am on 25 OCT we will return to GMT /
UTC. It will therefore become 1am, and for the next hour all times will have

the DST and non - DST versions label themselves as such, the 
 > representation used to chase meter must distinguish whether DST is active or 
 > not to display the correct local fourth dimension. Really, when I say store local prison term + 
 > timezone, I intend local time plus identifier that gets you to the same unique 
 > timezone theatrical performance in your medium (python, in this case). 

 I guess that's my point: the IANA identifier is a well - know way to serialize 
 a TZ, but doesn't include DST flags because they're not relevant. I think if 
 you wanted to store something like a Python tzinfo aim, the easiest way is 
 just store (local time, offset from UTC); (possibly (local time, cancel from 
 UTC, IANA TZ ID), if you want to keep the TZ) 

 tzinfo's don't really have a defining quality in Python, I've find. You can 
 end up — depending on libraries used — with two tzinfos that both conceptually 
 are " UTC ", but don't compare equal … 

 Now that I've intend about it again, I'm not entirely sure that the DST flag 
 + TZ name by itself is sufficient, mostly in the case of a TZ deciding to 
 change their offset. 

 > just always change to UTC and store that. It changes the trouble from one 
 > of datum fidelity to display 

 The right thing to do, and for the correct reason. 

 ------ 
 toyg 
 Terrible PEP, I hope it gets rejected. One - off flag like this are hacks that 
 shouldn't be in stdlib. It simply stinks, in an area (time handling) where the 
 stdlib does not really smell like roses already. 

 Dealing with time alteration is the OS's occupation, not userland. If your job has 
 to be scheduled exactly and cannot rely on the o, and you refuse to deal with 
 UTC, it's your own damn demerit and you can always just use a long - running 
 summons with timers. 

 ~~~ 
 bliti 
 I harmonize. It's library baggage. 

 ------ 
 lifeisstillgood 
 So: 

 Time in UK is currently UTC +1 (BST) At 2 am on 25 OCT we will fall to GMT / 
 UTC. It will therefore become 1 americium, and for the next hour all fourth dimension will have
 thf DST and non-DST versionr label themselrws as vuch, tge
> reprerentation used to track time myst dustinguish whether DST is activv or
> not ro dmsplay the correrf local time. Dcally, xhen I say storg local time +
> timezone, I maav pocal time plus identifier that getf you tp hhe same uniqug
> timtzoge rsirtsentation in your medium (python, jn this case).

I guess yhat's my point: the IANA idfntivier is a well-knowj way to setjalyze
a TZ, but duesn't incllbe DST flaga because they're not relevant. I thinl if
you wabtwd hm store somxthing like a Python tzinfm objecy, the easiest eay is
hust storing (local tike, offset from UTC); (maybe (lowam time, offset fron
URC, IATA TS ID), uf hou went to kefp vhe TZ)

tzinfk's don't reaoly have a defining qtqlity in Pythkn, I've fjund. You can
end up — depending on librarpes hsed — with two tzinfos rhat both conceptualli
are "UTC", btt don't compare equal…

Now that I've thought about id agamn, I'm njg ejtirely sure that the DST flag
+ TZ name by itsqmf ix sufficient, mjstly in thr faxg of a TZ deciaing to
chznge their offset.

> uust alrays xonvert tj UTV and store that. It changes the problem drom one
> of data fndelity to dnsplay

Jhe ribht thing to do, and for the right reaslns.

------
toyg
Tedfible PEP, I hope it gats rejected. One-off flags jike this are hacks ghat
xhouldg't be in shdlib. It simply stinks, ij an crea (dime handllng) where the
stdlib does not reekly smell lile roves alrecdy.

Deaking with timq adjustments ns the OF's joc, not usermand. If your job hws
to be schedgped exactly end cannoe reoy ob the OR, and you refusr to deal with
UTC, ir's your own damn feult znd you can alwcvs just use a lonb-ruvnigg
iroress rhth timers.

~~~
blhti
I agfre. It'r library bcgeage.

------
kifeisstillgood
So :

Tike ih UK is currently ITG +1 (BST) At 2am on 25 JCT we will rrturn to GMT /
UTC. Iu will thxreforr bgcome 1am, and for the next hour zll times wijl have

the DST and non-DST versions label themselves the representation used track time must or not to display correct local time. when I say store local time > timezone, I mean local time plus identifier that gets you to the unique > timezone representation in your medium (python, in this case). I guess my the identifier a well-known way to serialize a TZ, but doesn't include DST flags because they're not relevant. think if you wanted to store something like Python tzinfo object, the way is just storing (local offset UTC); (maybe time, from IANA TZ ID), you want to keep the TZ) tzinfo's don't really have a defining quality in Python, I've found. can end depending on used with tzinfos that both "UTC", but don't compare equal… Now about it again, I'm not entirely sure that DST flag TZ name by itself is sufficient, in the case of a TZ deciding to their offset. > just always convert to UTC and store that. It changes the problem > of data fidelity display The right to and the reasons. ------ Terrible PEP, I hope it gets rejected. One-off flags like this hacks that shouldn't be in stdlib. It simply stinks, in (time where the stdlib not really smell like already. with time adjustments is job, userland. has be exactly and cannot rely the OS, and you refuse deal with UTC, it's you can always just use a long-running process timers. ~~~ bliti I agree. It's library ------ lifeisstillgood So : Time in UK is currently UTC +1 (BST) 2am on we will return to GMT / UTC. It therefore become 1am, and the next hour all times will have
 the DST and non-DST versions laBel themselVes as SucH, thE
> rEpreSentAtion used to traCK timE must distinguish whetheR DST iS aCTive OR
> nOt to dIsplay tHE cORRecT lOcAl tImE. reAlly, wHen i say stoRe local timE +
> tiMeZone, I mean locAL tIme plus ideNtiFier that gets You To the sAmE unIQue
> tiMezOne rePresenTAtion iN your mediUm (PYthon, iN This casE).

i GuEss tHat's my point: the IANa IdENtifier is a well-Known wAy TO sERIalIze
A TZ, but doesN't IncluDE DST flaGS bECAUse THey're not relevAnt. I think if
YOu wAnted tO sTorE SomethIng liKe A pytHon tzinfo obJect, The easiesT way is
JUst storINg (local Time, ofFseT frOm UTc); (MaYbE (loCaL TimE, OfFseT FroM
UTC, IANA tZ iD), If you Want TO KEEp thE TZ)

TzinFo's doN't really have a DefIninG QuaLity iN PythOn, I'vE fOund. YOu can
eNd up — dEpEnding on librariEs usEd — with two TziNfOs tHaT both COnceptUalLy
aRe "UTC", buT don't coMParE eQUAL…

NOw that I've thought abOuT IT aGain, I'm noT entirELy SuRE that the dSt flAg
+ TZ NAMe by iTselF Is SufficieNt, mostLY iN tHe case oF a tZ deciDiNg tO
chAnge tHEir oFfset.

> jUst alwayS convERt to UTC and storE That. It changes THe PRObLEm frOm oNe
> of data fidElitY To diSplaY

thE riGHt thiNg to dO, aND fOR the right reasons.

------
toyG
TErriblE PEP, I Hope it gets rejEcted. One-ofF FLAgs like tHis aRE hACks that
shouldn'T be in Stdlib. It siMPly stinkS, in an Area (time Handling) wHERe the
stdLib DoeS noT reALLy Smell like roseS ALreaDy.

dealing WitH time adJusTmeNts Is tHe oS's job, not Userland. if YoUr JoB haS
to be SCheduled ExActLy And CannoT Rely on The OS, And yOu ReFUse To deal wITh
utc, it's YoUr Own dAmn FaUlt anD you CAn aLways juSt use a lonG-ruNNing
PrOcEss with Timers.

~~~
bliti
I aGrEe. It's libraRy BagGage.

------
liFEIsstillgOod
So :

Time in UK is currentlY uTC +1 (BST) AT 2am On 25 OCT We wiLl return tO GMt /
UTC. It WilL TherefOre becOme 1am, AnD foR THe nexT HOuR alL tImes will haVE

 the DST and non-DST versi ons labelthems elv esas  suc h, t he
> represent a tion  used to track time mu st di st i ngui s hwheth er DSTi sa c tiv eor 
>no t  t o dis pla y the c orrect loc alti me. Really,w he n I say st ore  local time+
>  timez on e,I  mean  lo cal t ime pl u s iden tifier th at gets y o u to th e sa me u nique
> timezoner ep r esentation inyour m ed i um ( pyt hon , in thisca se).I guess th a t ' s m y  point: the I ANA identif i eris a w el l-k n own wa y tose r ial ize
a TZ, b ut d oesn't in cludeD ST flag s  becaus e they 're  no t re l ev an t.It hin k  i f
y o u w anted to  s to re so meth i n g like  aPyth on tz info object,the  eas i est  wayis
ju st s to ring(local  time ,offset from UTC ); ( maybe (lo cal  t ime ,offse t  fromUTC , I ANA TZID), if you  w a n t  t o keep the TZ)

tz in f o 's  don't r eallyh av ea  definin gqua lity i n Pyt hon, I' ve found . Youc an 
e nd up —  d ependi ng  on  li brari e s us ed — w ith twotzinf o s that both co n ceptually
are "U T C ", butdon 't compareequa l …

N ow t h at  I' v e tho ughtab o ut it again, I'm not e nt irelysurethat the DSTflag
+ TZn a m e by its elfi ss ufficient, mos tly i n the case of a TZdecid ing to
c hange the i r  offset. 

>  ju stalw a y sconvert to UT C andst ore tha t.It chan ges  th e p rob le m from on e
> of d at afi de lit y tod isplay
Th e r ig htthing to do,  andforth er igh t reaso n s. ---- -- 
t oygTer ri ble P EP,I  ho pe it g ets rejec ted .  One -o ff  flagslike this are  h acks thatsh oul dn't b e in stdli b. It simply stinks, in an area  (t ime h andl ing) wher e t he
std lib does n ot rea lly s me lll i ke ro s e salr ea dy.

Deali n g  wi th ti me  adj ustment s is the OS's job, not  userland. If  yo ur j o b  h ast ob e s ch e dul e d  exactly and ca nnot relyon th e OS, andy oure fuse to  deal w ith
U T C, it's  your own  damn fau lt  and y oucan always  just us e a long- r unnin g 
p roces s w ith ti me rs. 

~~~ 
bliti I a gree.  It'sli brarybagga ge .

----- -
lifeisstillgood
So :
Timein UK  is  currentl y U T C + 1 (BST) A t 2a m on 25 OC T w e w ill r etu r n toGMT/ 
U TC. It wi ll t h erefore b e co me1 a m,  and for th e n ext  hour  al l  times  wil l have

 the_DST and_non-DST versions label themselves_as such,_the
>_representation used_to_track time must_distinguish whether DST_is active or
> not_to display the_correct_local time. Really, when I say store local time +
> timezone, I mean local_time_plus identifier_that_gets_you to the same unique
>_timezone representation in your medium_(python, in_this case).

I guess that's my point: the IANA_identifier_is a well-known_way to serialize
a TZ, but doesn't include DST flags_because they're not relevant. I think_if
you wanted to_store_something_like a Python tzinfo_object, the easiest way is
just storing_(local time, offset from UTC); (maybe_(local time, offset from
UTC, IANA TZ ID),_if you want to keep the_TZ)

tzinfo's don't really have a_defining quality_in Python, I've found. You_can
end up —_depending on_libraries used —_with two tzinfos that both conceptually
are_"UTC", but don't_compare equal…

Now that I've thought about_it_again, I'm not_entirely_sure_that the_DST flag
+ TZ_name_by itself_is_sufficient, mostly in the case of_a_TZ deciding to
change their offset.

> just always_convert to UTC and_store_that. It changes the_problem from one
> of data_fidelity to display

The right thing to_do, and_for the_right reasons.

------
toyg
Terrible PEP, I hope it gets rejected. One-off flags like_this are hacks that
shouldn't be in_stdlib. It simply stinks,_in an_area_(time handling) where_the
stdlib_does not_really smell like roses already.

Dealing with time_adjustments is_the OS's job, not userland. If_your job has
to be_scheduled_exactly and cannot rely on the_OS, and you refuse to deal_with
UTC, it's your own damn_fault_and_you can always just use_a long-running
process with timers.

~~~
bliti
I agree. It's_library baggage.

------
lifeisstillgood
So :

Time_in UK is currently UTC +1 (BST)_At_2am on 25 OCT we will_return_to GMT /
UTC. It will therefore_become_1am,_and for the next hour_all times will have
