title: IPython: ImportError: No module named mymodule
body: <p>I am experience this annoying error message, every time after I have updated my module and try to reload it.</p>
  <p><strong>I do have a module <code>mymodule</code> in a package <code>mypackage</code> that has a <code>__init___.py</code> file in it.</strong></p>
  <p>When I do</p>
  <pre><code>from mypackage import mymodule
  </code></pre>
  <p>everything is ok.</p>
  <p>After I update the module and reload it with</p>
  <pre><code>reload(mymodule)
  </code></pre>
  <p>Error pops up:</p>
  <pre><code>In [4]: 
     ...: reload(constants)
  ---------------------------------------------------------------------------
  ImportError                               Traceback (most recent call last)
  &lt;ipython-input-4-264a569b44f9&gt; in &lt;module&gt;()
        1 
  ----&gt; 2 reload(mymodule)
  
  ImportError: No module named mymodule
  </code></pre>
  <p>To resolve this, <strong>I have to kill my interpreter and re-import everything when I want to reload one module</strong>, which is extremely time-consuming and annoying. How may I fix it?</p>
  <p><strong>PS:</strong>
  I suspect this is something wrong with <code>PYTHONPATH</code>, but since I am using Python tool for Visual Studio, I cannot find the <code>PYTHONPATH</code> option.</p>
  <hr />
  <h1>Update</h1>
  <p>As far as I remember, it seems that things start going wrong immediately after I have this</p>
  <pre><code>import os
  os.chdir(constants.PROJECT_PATH + '//data//')
  </code></pre>
  <p>in one of the modules. Yet does it really matter?</p>
  <p>I don't think it matters, as the path in the brackets is exactly my project path.</p>