Python error: No module named Setuptools workaround

Source: Internet
Author: User

Mysql-python is a third-party module library for Python to access the MySQL database;


The following error occurred during the installation process:

[[email protected] mysql-python-1.2.5]# python setup.py install

Traceback (most recent):

File "setup.py", line 7, <module>

Import Setuptools

Importerror:no module named Setuptools


It literally means: There is no setuptools module, which means Python lacks this module;


Here's how to fix it:


Download Setuptools Package

# wget http://pypi.python.org/packages/source/s/setuptools/setuptools-0.6c11.tar.gz


Unzip the Setuptools bag

# TAR-XVF Setuptools-0.6c11.tar.gz

# CD SETUPTOOLS-0.6C11


Compiling Setuptools

# python setup.py Build


Start performing setuptools Installation

# python setup.py Install


Installation completed;

# ls-l/usr/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg

-rw-r--r--. 1 root root 333591 Mar 14:21/usr/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg


Perform the above operation again without error;


This article is from the "Model Student's Learning blog" blog, please be sure to keep this source http://mofansheng.blog.51cto.com/8792265/1911395

Python error: No module named Setuptools workaround

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.