title: Downloading files based on timestamp in Python
body: <p>I'm trying to create a method that allows me to download files from a server (using HTTP) only if the file is newest than the version already downloaded to my computer.</p>
  
  <p>I found a way to get the last time that the file was modified on the server (at least the last time that the server thinks that it was modified):</p>
  
  <pre><code>u = urllib2.urlopen(url)
  meta = u.info()
  print("Last Modified: " + str(meta.getheaders("Last-Modified")))
  </code></pre>
  
  <p>The problem now is how to use this information to compare with the files that I already have on my computer and see if that version located on the server is newer than the version saved on my computer.</p>
  
  <p>I tried to use <code>python-wget</code> library; however, it didn't help. It is downloading everything and not even is overwriting the files (it is creating new ones), so I realized that that    library doesn't check the timestamp.</p>
  
  <p>What is the best way to solve that?  </p>