programing

setuptools라는 모듈이 없습니다.

nasanasas 2020. 10. 10. 10:09
반응형

setuptools라는 모듈이 없습니다.


Twilio의 설치 파일을 설치하고 싶습니다. 주어진 명령을 통해 설치할 때 오류가 발생합니다.

setuptools라는 모듈이 없습니다.

어떻게해야하는지 알려주세요.

나는 사용하고있다 python 2.7

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Python27>python D:\test\twilio-twilio-python-26f6707\setup.py install
Traceback (most recent call last):
  File "D:\test\twilio-twilio-python-26f6707\setup.py", line 2, in <module>
    from setuptools import setup, find_packages
ImportError: No module named setuptools

설치 setuptools하고 다시 시도하십시오.

시도 명령 :

sudo apt-get install -y python-setuptools

우분투 사용자의 경우 setuptool이 시스템 전체에 설치되지 않았기 때문에이 오류가 발생할 수 있습니다. 다음 명령을 사용하여 setuptool을 설치하십시오.

sudo apt-get install -y python-setuptools

python3의 경우 :

sudo apt-get install -y python3-setuptools

그 후, 다음을 사용하여 패키지를 정상적으로 다시 설치하십시오.

sudo python setup.py install

그게 다야.


Python의 경우이 명령 실행

apt-get install -y python-setuptools

Python 3.

apt-get install -y python3-setuptools

PyPA 권장 설치 및 파이썬 패키지입니다 관리하기위한 도구 pip. pipPython 3.4 ( PEP 453 )에 포함되어 있지만 이전 버전의 경우 설치 방법은 다음과 같습니다 (Windows에서 Python 3.3 사용).

https://bootstrap.pypa.io/get-pip.py 다운로드

>c:\Python33\python.exe get-pip.py
Downloading/unpacking pip
Downloading/unpacking setuptools
Installing collected packages: pip, setuptools
Successfully installed pip setuptools
Cleaning up...

샘플 사용법 :

>c:\Python33\Scripts\pip.exe install pymysql
Downloading/unpacking pymysql
Installing collected packages: pymysql
Successfully installed pymysql
Cleaning up...

귀하의 경우에는 다음과 같습니다 ( pipPython 버전과 독립적으로 캐시되는 것으로 보입니다 ).

C:\Python27>python.exe \code\Python\get-pip.py
Requirement already up-to-date: pip in c:\python27\lib\site-packages
Collecting wheel
  Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB)
    100% |################################| 69kB 255kB/s
Installing collected packages: wheel
Successfully installed wheel-0.29.0

C:\Python27>cd Scripts

C:\Python27\Scripts>pip install twilio
Collecting twilio
  Using cached twilio-5.3.0.tar.gz
Collecting httplib2>=0.7 (from twilio)
  Using cached httplib2-0.9.2.tar.gz
Collecting six (from twilio)
  Using cached six-1.10.0-py2.py3-none-any.whl
Collecting pytz (from twilio)
  Using cached pytz-2015.7-py2.py3-none-any.whl
Building wheels for collected packages: twilio, httplib2
  Running setup.py bdist_wheel for twilio ... done
  Stored in directory: C:\Users\Cees.Timmerman\AppData\Local\pip\Cache\wheels\e0\f2\a7\c57f6d153c440b93bd24c1243123f276dcacbf43cc43b7f906
  Running setup.py bdist_wheel for httplib2 ... done
  Stored in directory: C:\Users\Cees.Timmerman\AppData\Local\pip\Cache\wheels\e1\a3\05\e66aad1380335ee0a823c8f1b9006efa577236a24b3cb1eade
Successfully built twilio httplib2
Installing collected packages: httplib2, six, pytz, twilio
Successfully installed httplib2-0.9.2 pytz-2015.7 six-1.10.0 twilio-5.3.0

참고 URL : https://stackoverflow.com/questions/22531360/no-module-named-setuptools

반응형