>From my blog post on this topic [ http://tinyurl.com/4fw9u6 ]:



Look at what happens when I ask Django what version number it has (this is
from release 0.96.1):

==
[EMAIL PROTECTED]:~$ python
Python 2.5.1 (r251:54863, Mar 7 2008, 04:10:12)
[GCC 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import django
>>> django.VERSION
(0, 96.099999999999994, None)
>>> type(django.VERSION[1])

099999999999994 is not 0.1, which cannot be represented exactly in a
finite length floating point representation for any radix that is a power
of 2, if I understand correctly. I should be seeing (0, 96.1, None)
or, better yet, (0,96,1).
==

What's the third element of the tuple supposed to be?  How about 
making the tuple's value something like (0, 96, 1) for 
(major_version, minor_version, patch_level) or something
like that (probably with a better name than patch_level,
I don't know exactly what the Django semantics are
for the different parts of the versio number).

Any thoughts?

Peace,
Andrew

-- 
=======================================================
Andrew D. Ball <[EMAIL PROTECTED]>
software developer, American Research Institute, Inc.
http://www.americanri.com/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to