Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
I figured I might as well share the code I ended up using, in case anyone else wants an easy way to get strings to, for instance, SQL- storable datetimes. [EMAIL PROTECTED]:~$ cat test.py #!/usr/bin/python from datetime import datetime import subprocess def parsedate( date ): p = subprocess.P

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:35 pm, Jeffrey Froman <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > I need > > something to parse user input for a django app, and it's awesome to be > > able to write "last monday", "a year ago", or "10pm tuesday" like > > PHP's strtotime. > > Django comes with some pretty

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:33 pm, Carl Banks <[EMAIL PROTECTED]> wrote: > On Mar 7, 5:08 pm, [EMAIL PROTECTED] wrote: > > > I'm new to python and I was wondering if there are any intelligent > > date/time parsing modules out there. I've looked at strptime (or > > whichever it is) and mxDateTime from the eGenix pa

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:22 pm, [EMAIL PROTECTED] wrote: [snip] > Although if I end up writing my own I'll sure use > datetime.parser.parse to get everything left over once you remove I mean dateutil.parser.parse. Tomorrow I'll have to leave off the last Lunchtime Guiness. > strings like "this saturday". So it

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:10 pm, Mike Driscoll <[EMAIL PROTECTED]> wrote: > On Mar 7, 4:08 pm, [EMAIL PROTECTED] wrote: > > > I'm new to python and I was wondering if there are any intelligent > > date/time parsing modules out there. I've looked at strptime (or > > whichever it is) and mxDateTime from the eGenix

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:10 pm, Mike Driscoll <[EMAIL PROTECTED]> wrote: > On Mar 7, 4:08 pm, [EMAIL PROTECTED] wrote: > > > I'm new to python and I was wondering if there are any intelligent > > date/time parsing modules out there. I've looked at strptime (or > > whichever it is) and mxDateTime from the eGenix

Re: Intelligent Date & Time parsing

2008-03-07 Thread shakefu
On Mar 7, 4:08 pm, [EMAIL PROTECTED] wrote: > I'm new to python and I was wondering if there are any intelligent > date/time parsing modules out there. I've looked at strptime (or > whichever it is) and mxDateTime from the eGenix package. I need > something to parse user input for a django app, and

Intelligent Date & Time parsing

2008-03-07 Thread shakefu
I'm new to python and I was wondering if there are any intelligent date/time parsing modules out there. I've looked at strptime (or whichever it is) and mxDateTime from the eGenix package. I need something to parse user input for a django app, and it's awesome to be able to write "last monday", "a