title: Python doesn't work: ImportError: No module named 'logging'
body: <p>I'm experiencing a very strange issue on my Digitalocean Ubuntu droplet, where Python 2.7 gives me the following error:</p>
  
  <pre><code>  from instagram import InstagramAuthentication, InstagramAPI
    File "/root/instagram_insights/socialgraphs-final-assignment/instagram.py", line 1, in &lt;module&gt;
      import requests
    File "/usr/lib/python2.7/dist-packages/requests/__init__.py", line 55, in &lt;module&gt;
      import urllib3
    File "/usr/lib/python2.7/dist-packages/urllib3/__init__.py", line 10, in &lt;module&gt;
      from .connectionpool import (
    File "/usr/lib/python2.7/dist-packages/urllib3/connectionpool.py", line 2, in &lt;module&gt;
      import logging
  ImportError: No module named logging
  </code></pre>
  
  <p>In fact, I can't do <strong>anything</strong> with Python:</p>
  
  <ol>
  <li>If I'm trying to reinstall python through <code>apt-get</code> I get the same error</li>
  <li>If I'm trying to execute a any pip command, e.g. <code>pip search logging</code>, I get the error</li>
  <li>I can't even create a new virtualenv by doing <code>virtualenv venv</code> without getting the same error</li>
  </ol>
  
  <p>My <code>PYTHONPATH</code> looks like this:
  <code>
  ['', '/usr/local/lib/python2.7/dist-packages/gunicorn-19.3.0-py2.7.egg', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages']
  </code></p>
  
  <p>The funny thing is that the error appeared out of the blue until I restarted gunicorn, which is the WSGI server I'm using to host my Flask site.</p>
  
  <p>Before it happened I was fiddling with logs in <code>nginx</code>, but I can't see how that should have affected my Python installation.</p>