I need to parse RFC 3339 strings like \"2008-09-03T20:56:35.450686Z\"
into Python\'s datetime
type.
I have found strptime in the Python sta
I have found ciso8601 to be the fastest way to parse ISO 8601 timestamps. As the name suggests, it is implemented in C.
import ciso8601
ciso8601.parse_datetime('2014-01-09T21:48:00.921000+05:30')
The GitHub Repo README shows their >10x speedup versus all of the other libraries listed in the other answers.
My personal project involved a lot of ISO 8601 parsing. It was nice to be able to just switch the call and go 10x faster. :)
Edit: I have since become a maintainer of ciso8601. It's now faster than ever!