I'm looking for a function that can convert an English date phrase 开发者_如何转开发to some kind of Python date object representing the appropriate date.
An example of the kinds of things I'm looking for (though I'm flexible):
- Three days from now
- yesterday
- In a month
- Next year
- January 18, 2011
- Next Wednesday
Is there such a thing? Is there one perhaps in another language?
parsedatetime, always a classic: http://code.google.com/p/parsedatetime/
I think the best bet here would be the mxDateTime. The documentation seems to suggest that it does what you're looking for.
精彩评论