David Fraser wrote:
Hi
I have been testing out pypy for the first time... I wanted to get the datetime module working and found that there was a pure python implementation of it done before the C implementation, in the nondist/sandbox/datetime module on Python CVS. This implementation works fairly well on pypy: - in order to test it, the attached patch to test_datetime is needed to avoid problems with pickle and gc - other than pickling, the only test failures are below The datetime.py can be got directly here: http://cvs.sourceforge.net/viewcvs.py/*checkout*/python/python/nondist/sandbox/datetime/datetime.py?content-type=text%2Fplain&rev=1.160
To speed up my testing I created a cutdown version of the non-pickle tests that failed :-) One of them fails in standard python as well so is a problem with the datetime.py code The others are all due to classmethod not accepting keyword arguments. I've attached a patch to __builtin__module.py that enables it to accept keyword arguments, which makes all those tests pass. Seems simple, could it be applied? David