How to install mechanize for Python 2.7? How to install mechanize for Python 2.7? python python

How to install mechanize for Python 2.7?


using pip:

pip install mechanize

or download the mechanize distribution archive, open it, and run:

python setup.py install


Try this on Debian/Ubuntu:

sudo apt-get install python-mechanize


You need to follow the installation instructions and not just download the files into your Python27 directory. It has to be installed in the site-packages directory properly, which the directions tell you how to do.