Cant import psycopg2
<p>I am trying to install postgresql_python.
I downloaded the tarball and installed it using:
python setup.py build
python setup.py install</p>

<p>I got /usr/lib64/python2.4/site-packages/psycopg2/ with</p>

<pre><code>&gt; total 836
&gt; -rw-r--r-- 1 root root  12759 Dec 11 18:18 errorcodes.py
&gt; -rw-r--r-- 1 root root  14584 Dec 12 13:49 errorcodes.pyc
&gt; -rw-r--r-- 1 root root  14584 Dec 12 13:49 errorcodes.pyo
&gt; -rw-r--r-- 1 root root   5807 Dec 11 18:18 extensions.py
&gt; -rw-r--r-- 1 root root   7298 Dec 12 13:49 extensions.pyc
&gt; -rw-r--r-- 1 root root   7298 Dec 12 13:49 extensions.pyo
&gt; -rw-r--r-- 1 root root  31495 Dec 11 18:18 extras.py
&gt; -rw-r--r-- 1 root root  35124 Dec 12 13:49 extras.pyc
&gt; -rw-r--r-- 1 root root  35124 Dec 12 13:49 extras.pyo
&gt; -rw-r--r-- 1 root root   6177 Dec 11 18:18 __init__.py
&gt; -rw-r--r-- 1 root root   5740 Dec 12 13:49 __init__.pyc
&gt; -rw-r--r-- 1 root root   5740 Dec 12 13:49 __init__.pyo
&gt; -rw-r--r-- 1 root root   8855 Dec 11 18:18 pool.py
&gt; -rw-r--r-- 1 root root   8343 Dec 12 13:49 pool.pyc
&gt; -rw-r--r-- 1 root root   8343 Dec 12 13:49 pool.pyo
&gt; -rw-r--r-- 1 root root   3389 Dec 21 11:17 psycopg1.py
&gt; -rw-r--r-- 1 root root   3182 Dec 21 11:22 psycopg1.pyc
&gt; -rw-r--r-- 1 root root   3167 Dec 12 13:49 psycopg1.pyo
&gt; -rwxr-xr-x 1 root root 572648 Dec 21 11:22 _psycopg.so drwxr-xr-x 2 root root   4096 Dec 21 10:38 tests
&gt; -rw-r--r-- 1 root root   4427 Dec 11 18:18 tz.py
&gt; -rw-r--r-- 1 root root   4325 Dec 12 13:49 tz.pyc
&gt; -rw-r--r-- 1 root root   4325 Dec 12 13:49 tz.pyo
</code></pre>

<p>But in python shell when I am trying to import library, I got error:</p>

<pre><code>&gt;&gt;&gt; import psycopg2
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in ?
  File "/usr/lib64/python2.4/site-packages/psycopg2/__init__.py", line 76, in ?
    from psycopg2._psycopg import _connect, apilevel, threadsafety, paramstyle
ImportError: cannot import name _connect
</code></pre>

<p>I am running with Postgresql 9.2.</p>

<p>What am I missing here?
Please let me know.</p>

<p>Thanks.</p>
