Try 30 days of free premium.

Question about Episode airstamp format

liiight wrote 8 years ago: 1

This is the string of the episode airstamp:

"airstamp":"2013-06-24T22:00:00-04:00"

The "-04:00" part at the end is the UTC offset right? If so, would it be possible to return it in the conventional "-0400" format without the colon?
It'll be easier and more elegant to handle parsing that way instead of manipulating that entire string.


david wrote 8 years ago: 1

I can't change this without potentially breaking it for all existing users, or we'd have to create a whole new API version.

The format we use is consistent with ISO 8601, so any sane date-time library should understand it. :)

liiight wrote 8 years ago: 1

Turns out that python default datetime does not support that. Weird. Obviouslly there are other options which i'll use.
Thanks for the reply!


david wrote 8 years ago: 1

That's very strange! I'll keep it in mind for if we ever redo this part in the future :)

liiight wrote 8 years ago: 1

well python dateutil handles it without a problem.

Try 30 days of free premium.