title: How to convert an iterable to a stream?
body: <p>If I've got an iterable containing strings, is there a simple way to turn it into a stream? I want to do something like this:</p>
  
  <pre><code>def make_file():
      yield "hello\n"
      yield "world\n"
  
  output = tarfile.TarFile(…)
  stream = iterable_to_stream(make_file())
  output.addfile(…, stream)
  </code></pre>