无法在python中安装sslcommerz模块

问题描述 投票:0回答:2

我正在使用支付网关。我正在尝试安装一个软件包

pip install sslcommerz-python

但是命令提示符向我显示了这一点

(venv) C:\Users\ITS\Desktop\my-e-com-project\venv\Scripts>pip install sslcommerz-python
Collecting sslcommerz-python
  Using cached sslcommerz-python-0.0.7.tar.gz (4.1 kB)
Requirement already satisfied: astroid==2.3.3 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (2.3.3)
Requirement already satisfied: certifi==2019.11.28 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (2019.11.28)
Requirement already satisfied: chardet==3.0.4 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (3.0.4)
Requirement already satisfied: idna==2.8 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (2.8)
Requirement already satisfied: isort==4.3.21 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (4.3.21)
Requirement already satisfied: lazy-object-proxy==1.4.3 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (1.4.3)
Requirement already satisfied: mccabe==0.6.1 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (0.6.1)
Requirement already satisfied: requests==2.22.0 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (2.22.0)
Requirement already satisfied: six==1.13.0 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (1.13.0)
Collecting typed-ast==1.4.0
  Using cached typed_ast-1.4.0.tar.gz (206 kB)
Requirement already satisfied: urllib3==1.25.7 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (1.25.7)
Requirement already satisfied: wrapt==1.11.2 in c:\users\its\desktop\my-e-com-project\venv\lib\site-packages (from sslcommerz-python) (1.11.2)
Using legacy 'setup.py install' for sslcommerz-python, since package 'wheel' is not installed.
Using legacy 'setup.py install' for typed-ast, since package 'wheel' is not installed.
Installing collected packages: typed-ast, sslcommerz-python
    Running setup.py install for typed-ast ... error
    ERROR: Command errored out with exit status 1:
     command: 'c:\users\its\desktop\my-e-com-project\venv\scripts\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ITS\\AppData\\Local\\Temp\\pip-install-o5i5b553\\typed-ast\\setup.py'"'"'; __file__='"'"'C:\\Users\\ITS\\AppData\\Local\\Temp\\pip-install-o5i5b553\\typed-ast\\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\ITS\AppData\Local\Temp\pip-record-2mlim41m\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\its\desktop\my-e-com-project\venv\include\site\python3.9\typed-ast'
         cwd: C:\Users\ITS\AppData\Local\Temp\pip-install-o5i5b553\typed-ast\
    Complete output (16 lines):
    running install
    running build
    running build_py
    creating build
    creating build\lib.win-amd64-3.9
    creating build\lib.win-amd64-3.9\typed_ast
    copying typed_ast\ast27.py -> build\lib.win-amd64-3.9\typed_ast
    copying typed_ast\ast3.py -> build\lib.win-amd64-3.9\typed_ast
    copying typed_ast\conversions.py -> build\lib.win-amd64-3.9\typed_ast
    copying typed_ast\__init__.py -> build\lib.win-amd64-3.9\typed_ast
    package init file 'ast3\tests\__init__.py' not found (or not a regular file)
    creating build\lib.win-amd64-3.9\typed_ast\tests
    copying ast3\tests\test_basics.py -> build\lib.win-amd64-3.9\typed_ast\tests
    running build_ext
    building '_ast27' extension
    error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\users\its\desktop\my-e-com-project\venv\scripts\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ITS\\AppData\\Local\\Temp\\pip-install-o5i5b553\\typed-ast\\setup.py'"'"'; __file__='"'"'C:\\Users\\ITS\\AppData\\Local\\Temp\\pip-install-o5i5b553\\typed-ast\\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\ITS\AppData\Local\Temp\pip-record-2mlim41m\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\its\desktop\my-e-com-project\venv\include\site\python3.9\typed-ast' Check the logs for full command output.

这个问题有什么解决办法吗? 预先感谢。

python pip package payment
2个回答
0
投票

https://visualstudio.microsoft.com/visual-cpp-build-tools/

从此站点下载 Microsoft C++ 构建工具。

转到 Visual Studio 2017 的构建工具

在 Visual Studio Community 2017 下选择免费下载。这将下载安装程序。运行安装程序。

选择使用 C++ 进行桌面开发。

https://i.stack.imgur.com/vMhnK.png


0
投票

安装缺少的模块:

确保您的 Python 环境中安装了 “sslcommerz_lib” 模块。您可以使用 Python 包管理器 pip 安装它,方法是在终端或命令提示符中运行以下命令:

pip install sslcommerz_lib

希望这对你有帮助😍.

© www.soinside.com 2019 - 2024. All rights reserved.