Re: More puzzling behavior while subclassing datetime

2006-11-16 Thread [EMAIL PROTECTED]
> Yes. Consider: > > >>> def today(time=None, *args): > ... print "time = ", time, "args = ", args > ... > >>> today(2006, 11, 16) > time = 2006 args = (11, 16) > > To fix the issue you'll probably have to remove the time=None parameter from > GeneralizedTime.__new__() and instead extract it

Re: More puzzling behavior while subclassing datetime

2006-11-16 Thread Peter Otten
[EMAIL PROTECTED] wrote: > With assistance from Gabriel and Frederik (and a few old threads in > c.l.p.) I've been making headway on my specialized datetime class. Now > I'm puzzled by behavior I didn't expect while attempting to use some of > the alternate datetime constructors. Specifically, i

Re: More puzzling behavior while subclassing datetime

2006-11-16 Thread [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote: > With assistance from Gabriel and Frederik (and a few old threads in > c.l.p.) I've been making headway on my specialized datetime class. Now > I'm puzzled by behavior I didn't expect while attempting to use some of > the alternate datetime constructors. Specifically, i

More puzzling behavior while subclassing datetime

2006-11-15 Thread [EMAIL PROTECTED]
With assistance from Gabriel and Frederik (and a few old threads in c.l.p.) I've been making headway on my specialized datetime class. Now I'm puzzled by behavior I didn't expect while attempting to use some of the alternate datetime constructors. Specifically, it appears if I call GeneralizedTim