title: How can I access s3 files in Python using urls?
body: <p>I want to write a Python script that will read and write files from s3 using their url's, eg:'s3:/mybucket/file'.  It would need to run locally and in the cloud without any code changes.  Is there a way to do this?</p>
  
  <p>Edit: There are some good suggestions here but what I really want is something that allows me to do this:</p>
  
  <pre><code> myfile = open("s3://mybucket/file", "r")
  </code></pre>
  
  <p>and then use that file object like any other file object.  That would be really cool.  I might just write something like this for myself if it doesn't exist.  I could build that abstraction layer on simples3 or boto.</p>