How best to test functions which use

Christian Heimes lists at
Sat Feb 28 19:39:35 CET 2009

Lie Ryan wrote:
>> But this fails with:
>> TypeError: can't set attributes of built-in/extension type
>> ''
> This is because today is an attribute. In python, we can override
> attribute access to become a function call. I don't have python right
> now, but try this:
> del
> = mytoday

It won't work. The datetime module is written in C. You can't modify a C


More information about the Python-list mailing list