title: check_output error in python
body: <p>I am gettin a error while running the below code.  </p>
  
  <pre><code>#!/usr/bin/python
  import subprocess
  import os
  def check_output(*popenargs, **kwargs):
      process = subprocess.Popen(stdout=subprocess.PIPE, *popenargs, **kwargs)
      output, unused_err = process.communicate()
      retcode = process.poll()
      if retcode:
          cmd = kwargs.get("args")
          if cmd is None:
              cmd = popenargs[0]
          error = subprocess.CalledProcessError(retcode, cmd)
          error.output = output
          raise error
      return output
  
  location = "%s/folder"%(os.environ["Home"])
  subprocess.check_output(['./MyFile'])
  </code></pre>
  
  <p><strong>Error</strong></p>
  
  <pre><code>subprocess.check_output(['./MyFile'])
  AttributeError: 'module' object has no attribute 'check_output'
  </code></pre>
  
  <p>I am working on <code>Python 2.6.4</code> . </p>