python 运行python manege.py runserver时报错:“no module named djangorestframework” 的解决方案

时间:2022-04-19 09:08:25

python 运行python manege.py runserver时报错:“no module named djangorestframework” 的解决方案

importerror:no module named djangorestframework

Django REST framework is a powerful and flexible toolkit that makes it easy to build Web APIs.

Some reasons you might want to use REST framework:

djangorestframework安装

https://pypi.python.org/pypi/djangorestframework/0.3.2

下载解压

python setup.py install

如果提示

ImportError: No module named setuptools

则按如下步骤:

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

解压

tar zxvf setuptools-0.6c11.tar.gz
cd setuptools-0.6c11
python setup.py build

python setup.py install

再安装djangorestframework0.3.2

然后python setup.py install 就OK了