首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >安装pip install 'python-decouple‘时出错

安装pip install 'python-decouple‘时出错
EN

Stack Overflow用户
提问于 2020-09-08 04:32:44
回答 1查看 212关注 0票数 0
代码语言:javascript
复制
Collecting python-decouple
  Using cached python-decouple-3.3.tar.gz (10 kB)
Using legacy setup.py install for python-decouple, since package 'wheel' is not installed.
Installing collected packages: python-decouple
    Running setup.py install for python-decouple ... error
    ERROR: Command errored out with exit status 1:
     command: 'c:\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\slms_\\AppData\\Local\\Temp\\pip-install-awe0dvrf\\python-decouple\\setup.py'"'"'; __file__='"'"'C:\\Users\\slms_\\AppData\\Local\\Temp\\pip-install-awe0dvrf\\python-decouple\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\slms_\AppData\Local\Temp\pip-record-aljfw6bc\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\python38\Include\python-decouple'      
         cwd: C:\Users\slms_\AppData\Local\Temp\pip-install-awe0dvrf\python-decouple\
    Complete output (16 lines):
    running install
    running build
    running build_py
    creating build
    creating build\lib
    copying decouple.py -> build\lib
    running egg_info
    writing python_decouple.egg-info\PKG-INFO
    writing dependency_links to python_decouple.egg-info\dependency_links.txt
    writing top-level names to python_decouple.egg-info\top_level.txt
    reading manifest file 'python_decouple.egg-info\SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    writing manifest file 'python_decouple.egg-info\SOURCES.txt'
    running install_lib
    byte-compiling c:\python38\Lib\site-packages\decouple.py to decouple.cpython-38.pyc
    error: [Errno 13] Permission denied: 'c:\\python38\\Lib\\site-packages\\__pycache__\\decouple.cpython-38.pyc.2802584858032'
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\slms_\\AppData\\Local\\Temp\\pip-install-awe0dvrf\\python-decouple\\setup.py'"'"'; __file__='"'"'C:\\Users\\slms_\\AppData\\Local\\Temp\\pip-install-awe0dvrf\\python-decouple\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\slms_\AppData\Local\Temp\pip-record-aljfw6bc\install-rec
EN

回答 1

Stack Overflow用户

发布于 2021-01-26 19:57:57

您显然没有权限进行安装,您可以使用venv或以管理员身份运行cmd (idk,我不使用windows)

要设置venv,请在启动cmd时在项目目录中运行以下命令

代码语言:javascript
复制
C:\> python3 -m venv ./.venv 

然后运行安装脚本

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/63783886

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档