On Mon, Aug 18, 2014 at 9:12 AM, luofeiyu <elearn2...@gmail.com> wrote: > I found that it is a concept LMT local mean time can express my meaning.
Local Mean Time is time based on the actually astronomical position of the sun. It is defined as 12 noon when the sun is at its high point, directly south in the sky. This is the time you get when you read a sundial! So each town or village set their clocks differently. That all changed with the railroad industry. Once trains began traveling, time zones were invented so that everyone knew exactly what time it was in order to keep trains from meeting on the same tracks and colliding. Trains need time schedules. Time zones make this possible. Since the advent of time zones, you can be pretty well assured that the your LMT will be within a half hour or so (east or west) of the Time zone your location is assigned. But time zones are drawn for political reasons, and so that may not be precisely the case. In Indiana, USA there are (or were) several regions in different time zones. In the summer, they would change again, but not in step, so some places didn't switch to 'daylight savings time', and some did. Again, this had mostly to do with who the local business did business with, to keep time common for common trading partners. Off topic -- please remember to use plain text. > > import pytz,datetime > tz1 = pytz.timezone('Asia/Shanghai') > tz1 > <DstTzInfo 'Asia/Shanghai' LMT+8:06:00 STD> >>>> str(tz1) > 'Asia/Shanghai' > > tz2 = pytz.timezone('Asia/Urumqi') > tz2 > <DstTzInfo 'Asia/Urumqi' LMT+5:50:00 STD> > > the time difference between shanghai and Urumqi is about 2 hours in the form > of LMT. > > now ,how can i get the output of `LMT+8:06:00` in <DstTzInfo 'Asia/Shanghai' > LMT+8:06:00 STD> > > str(tz1) or str(tz2) can not do that. > > > -- > https://mail.python.org/mailman/listinfo/python-list > -- Joel Goldstick http://joelgoldstick.com -- https://mail.python.org/mailman/listinfo/python-list