ImportRrror: no module named 'psycopg2'
Question: I'm attempting to use PostgreSQL as my data base and I'm running into an issue
when I try to start my server. Here's what I'm doing:

  * I have a virtual environment set up and activated
  * Django 1.8.4 is installed
  * psycopg2 2.5.2 is installed
  * wheel 0.24.0 is installed

I'm using python 3.4.

Adding pip freeze output as requested:

    
    
    Django==1.8.4
    psycopg2==2.5.2
    wheel==0.24.0
    

when I run the server using the default sqlite3 db I have no issue; it runs
fine. As soon as I switch over to postgres I get the following error:
ImportError: no module named psycopg2.

`pip install psycopg2` wasn't working so I installed psycopg2 from github
using this command: `pip install
git+https://github.com/nwcell/psycopg2-windows.git@win64-py34#egg=psycopg2`

Guidance is greatly appreciated.


Answer: It is important to specify operating system you are on, as I guess from
comment you are using windows.

On windows if you do not wont to install Visual C++ libraries you can just
download whl file of the package.

<http://www.lfd.uci.edu/~gohlke/pythonlibs/#psycopg>

choose correct architecture and python version for you and run

    
    
    pip install path/to/packagename.whl
    

make sure you are using pip version 6 or newer

