Converting ISO 8061 datetimes to epoch timestamps

May 13th, 2011
python, tech
If you have something like:
2011-04-26T00:00:00Z-06
And you want to convert this into seconds since the epoch, apparently the incantation is:
int(time.mktime(dateutil.parser.parse(x).timetuple()))
This requires the dateutil module.

Recent posts on blogs I like:

On Transhumanism And Eugenics

Transhumanism as anti-ableist praxis

via Thing of Things June 7, 2024

Conversations I often have about parenting

Topics that come up a lot The post Conversations I often have about parenting appeared first on Otherwise.

via Otherwise June 4, 2024

Comments on the FTC antitrust investigation of Google

This is a summary of the publicly available documents on the 2011-2012 FTC investigation of Google's allegedly antitcompetive actions in search and ads, followed by a tech-focused analysis of the decision from someone who's worked at the two compa…

via Posts on May 26, 2024

more     (via openring)