[issue9909] request for calendar.dayofyear() function

2011-03-24 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- status: pending -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: h

[issue9909] request for calendar.dayofyear() function

2011-01-06 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: This is yet another request for functionality that can be implemented as a simple expression using datetime arithmetics. Also, issue #9864 is not a compelling use case because "the parsedate() function now returns a datetime object." See msg117496.

[issue9909] request for calendar.dayofyear() function

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: "We already got one, and it's very nice-a" ISTM, this should be done with regular date arithmetic in the datetime module. >>> date(1964, 7, 31) - date(1963, 12, 31) datetime.timedelta(213) I don't see why we need a new function for this or why it would be

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Abhay Saxena
Abhay Saxena added the comment: Quick hack alternative test. It would look nicer if the test used the datetime module, but I'm not sure that would be appropriate. def test_dayofyear(self):

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Abhay Saxena
Abhay Saxena added the comment: The test is incorrect on leap years for February 29, due to the way it constructs its list of dates. The function itself appears to give the right answer. -- nosy: +ark3 ___ Python tracker

[issue9909] request for calendar.dayofyear() function

2010-10-17 Thread JJeffries
JJeffries added the comment: I agree, I think this would be very useful. I use a function that does this quite often. Should also be added to calendar.py's __all__. -- nosy: +JJeffries ___ Python tracker

[issue9909] request for calendar.dayofyear() function

2010-09-20 Thread Jeffrey Finkelstein
New submission from Jeffrey Finkelstein : This is a function which computes the integer between 1 and 366 representing the day of the year, given a year, month, and day. The implementation I have provided computes the difference between the ordinal numbers of the given day and January first of