
Jeff Silver wrote:
Also, nice y2.043k trap there, I don't think many have been able to write ones targeting that exact date. Hmmm.. Not sure what you mean. If I read the Python 2.4 documentation correctly, these numbers will be handled as long integers. The subtraction just converts the 4-digit year at the start to 'years since 2000'. Am I missing something? If so, please say, and I can handle the year separately.
Size of python data types is pretty irrelevant when DNS SOA serial number is an unsigned 32-bit number. January 1st, 2043 would be 4301010000 YYMMDDHHMM which is > 2**32, and thus invalid. This is all pretty academical, of course. It's just that you've created a totally new _class_ of y2k-like bugs, with your YYYYMMDDHHMM - 200000000000 scheme, and I think that's worth some kind of a prize.