티스토리 뷰

728x90
datetime.datetime.fromisoformat('2019-01-04T16:41:24+02:00')

https://stackoverflow.com/questions/969285/how-do-i-translate-an-iso-8601-datetime-string-into-a-python-datetime-object

 

How do I translate an ISO 8601 datetime string into a Python datetime object?

I'm getting a datetime string in a format like "2009-05-28T16:15:00" (this is ISO 8601, I believe). One hackish option seems to be to parse the string using time.strptime and passing the first six

stackoverflow.com

 

728x90
댓글