This is the date format of AWS, how can I parse using and separate year day months and so on.
snapshot_time = str(snapshot_name.snapshot_create_time) snapshot_year = datetime.datetime.strptime(snapshot_time,"%Y-%m-%d-%H").year
Error: ValueError: time data '2014-08-09T04:31:39.870Z' does not match format '%Y-%m-%d-%H' I agree with the error, but how to fix it. I think part 09T04 is the problem area