title: How to convert a file to utf-8 in Python?
body: <p>I need to convert a bunch of files to utf-8 in Python, and I have trouble with the "converting the file" part.</p>
  
  <p>I'd like to do the equivalent of:</p>
  
  <pre><code>iconv -t utf-8 $file &gt; converted/$file # this is shell code
  </code></pre>
  
  <p>Thanks!</p>