[Checkins] SVN: DateTime/trunk/CHANGES.txt Add backwards compatibility notes for DateTime 3

Hanno Schlichting hannosch at hannosch.eu
Sat Jun 11 10:13:20 EDT 2011


Log message for revision 121908:
  Add backwards compatibility notes for DateTime 3
  

Changed:
  U   DateTime/trunk/CHANGES.txt

-=-
Modified: DateTime/trunk/CHANGES.txt
===================================================================
--- DateTime/trunk/CHANGES.txt	2011-06-11 02:32:44 UTC (rev 121907)
+++ DateTime/trunk/CHANGES.txt	2011-06-11 14:13:19 UTC (rev 121908)
@@ -4,7 +4,33 @@
 3.0 (unreleased)
 ----------------
 
+Backwards compatibility of DateTime 3
+*************************************
 
+DateTime 3 changes its pickle representation. DateTime instances pickled with
+former versions of DateTime can be read, but older DateTime versions cannot read
+DateTime instances pickled with version 3.
+
+DateTime 3 changes DateTime to be a new-style class with slots instead of being
+an old-style class.
+
+DateTime 3 tries to preserve microsecond resolution throughout most of its API's
+while former versions were often only accurate to millisecond resolution. Due to
+the representation of float values in Python versions before Python 2.7 you
+shouldn't compare string or float representations of DateTime instances if you
+want high accuracy. The same is true for calculated values returned by methods
+like `timeTime()`. You get the highest accuracy of comparing DateTime values by
+calling its `micros()` methods. DateTime is not particular well suited to be
+used in comparing timestamps of file systems - use the time and datetime objects
+from the Python standard library instead.
+
+Calling the DateTime constructor with a single argument of `None` will no longer
+create a DateTime instance representing `now`. Call the constructor without any
+arguments instead. The `None` case is a special case used during unpickling and
+requires you to call `__setstate__` to get a fully initialized instance.
+
+
+
 3.0b1 (2011-05-07)
 ------------------
 
@@ -64,14 +90,11 @@
   (non-) equality.
 
 - Fixed (possibly unused) _parse_iso8601 function.
-  [thet]
 
 - Removed unused import of legacy DateTimeZone, strftime and re.
   Remove trailing whitespace.
-  [thet]
 
 - Removed reference to missing version section from buildout.
-  [thet]
 
 2.12.6 (2010-10-17)
 -------------------



More information about the checkins mailing list