I know there are a lot of answers to this question online, but none of them have worked for me. I am trying to convert a date string into a Datetime object, of the following format: yyyy-mm-dd
My date_string
is '2017-02-02T00:00:00Z'
I am trying to convert it by doing date_value = datetime.datetime.strptime(date_string, '%Y%m%d')
but I'm getting the following error:
ValueError: time data '"2017-02-02T00:00:00Z"' does not match format '%Y%m%d'
Also, should I be worried about the double quotes around my date_string
string?