[Qt-interest] QDateTime daylight saving parsing time offset

Atlant Schmidt aschmidt at dekaresearch.com
Wed Mar 30 19:27:10 CEST 2011


Paul:

> Maybe it's just me but I've encountered so many bugs and issues with
> date/time code, I always tend to tread carefully these days. I'd
> rather ask stupid questions than wait for my app to break when the
> clocks go back :-)

  It's not just you. ;-)

  Testing our embedded assumptions around transitions to
  summertime/transitions from summertime/places that don't
  transition at all/other miscellaneous timezone changes
  and testing all of this assuming locations all around
  the world is hard, challenging work.

  Testing end-of-the-year rollover issues can be non-trivial.

  Making plans for the run-out of 32-bit time_t in 2038 is
  non-trivial. And much real-world software has a "time
  window much wider than 1970-2038 so there's a lot of
  hand-written "window-handler" code out there that also
  factors-in to your testing.

  A careful approach to date/time issues is always
  warranted.

                               Atlant



-----Original Message-----
From: qt-interest-bounces+aschmidt=dekaresearch.com at qt.nokia.com [mailto:qt-interest-bounces+aschmidt=dekaresearch.com at qt.nokia.com] On Behalf Of Paul Drummond
Sent: Wednesday, March 30, 2011 12:04
To: qt-interest at qt.nokia.com
Subject: Re: [Qt-interest] QDateTime daylight saving parsing time offset

Hi Thiago,

On 30 March 2011 16:33, Thiago Macieira <thiago at kde.org> wrote:
> I don't see why you'd spend the entire day to figure out what that +0100 means

I didn't mean I would need the whole day just for figuring out what
+0100 means.  I was in a rush this morning and got very confused about
the +0100 but that wasn't my question - I was really puzzled about why
QDateTime doesn't have the same "z" format specifier as Java
SimpleDateFormat (which I've used a lot).  Without the "z" specifier I
was unsure how to correctly convert the date string.

Maybe it's just me but I've encountered so many bugs and issues with
date/time code, I always tend to tread carefully these days. I'd
rather ask stupid questions than wait for my app to break when the
clocks go back :-)

Thanks for the responses - all helpful.

Paul Drummond.
_______________________________________________
Qt-interest mailing list
Qt-interest at qt.nokia.com
http://lists.qt.nokia.com/mailman/listinfo/qt-interest

This e-mail and the information, including any attachments, it contains are intended to be a confidential communication only to the person or entity to whom it is addressed and may contain information that is privileged. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the sender and destroy the original message.

Thank you.

Please consider the environment before printing this email.



More information about the Qt-interest-old mailing list