title: How to convert python timestamp string to epoch?
body: <p>I have the following string:</p>
  
  <pre><code>mytime = "2009-03-08T00:27:31.807Z"
  </code></pre>
  
  <p>How do I convert it to epoch in python?</p>
  
  <p>I tried:</p>
  
  <pre><code>import time
  p = '%Y-%m-%dT%H:%M:%S'
  int(time.mktime(time.strptime(s, p)))
  </code></pre>
  
  <p>But it does not work with the <code>31.807Z</code>.</p>