Page MenuHomeSolus

Update python-dateutil to 2.7.0
ClosedPublic

Authored by EP01 on Mar 13 2018, 12:52 AM.

Details

Summary

Release notes available here.

Test Plan

Executed the demo code below, and also tested with matplotlib, calibre, python-pandas, and python-jupyter_client.

In [1]: >>> from dateutil.relativedelta import *
   ...: >>> from dateutil.easter import *
   ...: >>> from dateutil.rrule import *
   ...: >>> from dateutil.parser import *
   ...: >>> from datetime import *
   ...: >>> now = parse("Sat Oct 11 17:13:46 UTC 2003")
   ...: >>> today = now.date()
   ...: >>> year = rrule(YEARLY,dtstart=now,bymonth=8,bymonthday=13,byweekday=FR)[0].year
   ...: >>> rdelta = relativedelta(easter(year), today)
   ...: >>> print("Today is: %s" % today)
   ...: 
Today is: 2003-10-11

In [2]: >>> print("Year with next Aug 13th on a Friday is: %s" % year)
Year with next Aug 13th on a Friday is: 2004

In [3]: print("How far is the Easter of that year: %s" % rdelta)
How far is the Easter of that year: relativedelta(months=+6)

In [4]: print("And the Easter of that year is: %s" % (today+rdelta))
And the Easter of that year is: 2004-04-11

Diff Detail

Repository
R2572 python-dateutil
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

EP01 created this revision.Mar 13 2018, 12:52 AM
EP01 requested review of this revision.Mar 13 2018, 12:52 AM
joebonrichie accepted this revision.Mar 13 2018, 10:33 PM
This revision is now accepted and ready to land.Mar 13 2018, 10:33 PM
This revision was automatically updated to reflect the committed changes.