title: Import error when calling method from same module in timeit()
body: <p>I want to measure the execution time of the Python method <em>sayHello()</em> using the method <em>getExecutionTime()</em>. They are both in a module and the <em>getExecutionTime()</em>-method should be callable from outside.</p>
  
  <p>The code looks like this:</p>
  
  <pre><code>def getExecutionTime():
      t = timeit.Timer("sayHello", "from __main__ import sayHello")
      return t.timeit(2)
  
  def sayHello():
      print("Hello")
  </code></pre>
  
  <p>I keep getting an ImportError saying: "Cannot import name sayHello in File ..."</p>
  
  <p>I added the scope argument (<code>"from __main__ import sayHello"</code>) to the Timer constructor to make the <em>sayHello()</em> method available within the timeit scope.</p>
  
  <p><strong>Note:</strong> I don't want to call getExecutionTime() in the main part of this method, I want to that method from somewhere else.</p>
  
  <p>Can anyone help?
  Thanks.</p>