0

I'm using Ubuntu 10.04 and had python 2.6 before. pycurl worked fine.

after I updated my python to 2.7, pycurl doesn't import

>>> import pycurl
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named pycurl

I tried to re-install python using

sudo apt-get install python-pycurl

It told me pycurl was already in the newest version

How do I fix it?

Thanks

cheng
  • 6,596
  • 6
  • 25
  • 27

2 Answers2

4

It should probably look something like this:

wget http://pycurl.sourceforge.net/download/pycurl-7.19.0.tar.gz
tar -xzf pycurl-7.19.0.tar.gz
cd pycurl-7.19.0
sudo python2.7 setup.py install
Andrew Clark
  • 202,379
  • 35
  • 273
  • 306
0

Try sudo pip install pycurl instead. Also, make sure that /usr/bin/python points to version 2.7.

Chinmay Kanchi
  • 62,729
  • 22
  • 87
  • 114