python-3.x PIPENV和pip3安装与PIPCPG 0.25.0和其他依赖项冲突

3z6pesqy  于 2023-10-21  发布在  Python
关注(0)|答案(1)|浏览(181)

我在Python 3.8环境中尝试安装Python cpg 0.25.0沿着其他依赖项时遇到了安装冲突。以下是我目前采取的步骤:
1.克隆存储库并创建虚拟环境。
1.已安装pipenv并尝试使用pipenv sync命令同步软件包。

Using pip 23.1.2 from /Users/me/.virtualenvs/auth-TKtQBmjM/lib/python3.9/site-packages/pip (python 3.9)
Requirement already satisfied: setuptools<=66 in /Users/virendra.pandey/.virtualenvs/auth-TKtQBmjM/lib/python3.9/site-packages (65.3.0)
Collecting asyncpg<0.26.0,>=0.25.0
 Using cached asyncpg-0.25.0.tar.gz (804 kB)
 Running command pip subprocess to install build dependencies
 Collecting setuptools>=42
   Using cached setuptools-68.0.0-py3-none-any.whl
 Collecting wheel
   Using cached wheel-0.40.0-py3-none-any.whl
 Installing collected packages: wheel, setuptools
 ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
 torpedo 2.7.4 requires aiocontextvars==0.2.2, which is not installed.
 torpedo 2.7.4 requires aiohttp==3.7.3, which is not installed.
 torpedo 2.7.4 requires aiotask-context==0.6.1, which is not installed.
 torpedo 2.7.4 requires async-timeout==3.0.1, which is not installed.
 torpedo 2.7.4 requires asynctest==0.13.0, which is not installed.
 torpedo 2.7.4 requires elastic-apm==6.7.1, which is not installed.
 torpedo 2.7.4 requires GitPython==3.1.27, which is not installed.
 torpedo 2.7.4 requires multidict==5.1.0, which is not installed.
 torpedo 2.7.4 requires psutil==5.8.0, which is not installed.
 torpedo 2.7.4 requires pydantic==1.9.0, which is not installed.
 torpedo 2.7.4 requires pytest==6.2.1, which is not installed.
 torpedo 2.7.4 requires pytest-cov==3.0.0, which is not installed.
 torpedo 2.7.4 requires python-json-logger==2.0.1, which is not installed.
 torpedo 2.7.4 requires sanic==21.12.1, which is not installed.
 torpedo 2.7.4 requires sentry-sdk==1.7.0, which is not installed.
 torpedo 2.7.4 requires tortoise-orm>=0.18.0, which is not installed.
 torpedo 2.7.4 requires ujson==4.1.0, which is not installed.
 torpedo 2.7.4 requires setuptools==65.3.0, but you have setuptools 68.0.0 which is incompatible.
 Successfully installed setuptools-68.0.0 wheel-0.40.0
 Installing build dependencies ... done
 Running command Getting requirements to build wheel

pipenv同步
输出量:

[pipenv.exceptions.InstallError]: Collecting asyncpg==0.25.0 (from -r /var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pipenv-1msbyp_n-requirements/pipenv-2b4rf_fm-hashed-reqs.txt (line 15))
[pipenv.exceptions.InstallError]:   Using cached asyncpg-0.25.0.tar.gz (804 kB)
[pipenv.exceptions.InstallError]:   Installing build dependencies: started
[pipenv.exceptions.InstallError]:   Installing build dependencies: finished with status 'done'
[pipenv.exceptions.InstallError]:   Getting requirements to build wheel: started
[pipenv.exceptions.InstallError]:   Getting requirements to build wheel: finished with status 'error'
[pipenv.exceptions.InstallError]: error: subprocess-exited-with-error
[pipenv.exceptions.InstallError]:   
[pipenv.exceptions.InstallError]:   × Getting requirements to build wheel did not run successfully.
[pipenv.exceptions.InstallError]:   │ exit code: 1
[pipenv.exceptions.InstallError]:   ╰─> [30 lines of output]
[pipenv.exceptions.InstallError]:       Traceback (most recent call last):
[pipenv.exceptions.InstallError]:         File "/Users/virendra.pandey/Library/Python/3.9/lib/python/site-packages/pipenv/patched/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
[pipenv.exceptions.InstallError]:           main()
[pipenv.exceptions.InstallError]:         File "/Users/virendra.pandey/Library/Python/3.9/lib/python/site-packages/pipenv/patched/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
[pipenv.exceptions.InstallError]:           json_out['return_val'] = hook(**hook_input['kwargs'])
[pipenv.exceptions.InstallError]:         File "/Users/virendra.pandey/Library/Python/3.9/lib/python/site-packages/pipenv/patched/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
[pipenv.exceptions.InstallError]:           return hook(config_settings)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 341, in get_requires_for_build_wheel
[pipenv.exceptions.InstallError]:           return self._get_build_requires(config_settings, requirements=['wheel'])
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 323, in _get_build_requires
[pipenv.exceptions.InstallError]:           self.run_setup()
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 338, in run_setup
[pipenv.exceptions.InstallError]:           exec(code, locals())
[pipenv.exceptions.InstallError]:         File "<string>", line 248, in <module>
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/__init__.py", line 107, in setup
[pipenv.exceptions.InstallError]:           return distutils.core.setup(**attrs)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 159, in setup
[pipenv.exceptions.InstallError]:           dist.parse_config_files()
[pipenv.exceptions.InstallError]:         File "/Users/virendra.pandey/.virtualenvs/auth-TKtQBmjM/lib/python3.9/site-packages/_virtualenv.py", line 23, in parse_config_files
[pipenv.exceptions.InstallError]:           result = old_parse_config_files(self, *args, **kwargs)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/dist.py", line 898, in parse_config_files
[pipenv.exceptions.InstallError]:           pyprojecttoml.apply_configuration(self, filename, ignore_option_errors)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/config/pyprojecttoml.py", line 66, in apply_configuration
[pipenv.exceptions.InstallError]:           config = read_configuration(filepath, True, ignore_option_errors, dist)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/config/pyprojecttoml.py", line 128, in read_configuration
[pipenv.exceptions.InstallError]:           validate(subset, filepath)
[pipenv.exceptions.InstallError]:         File "/private/var/folders/97/vp1ymp713bv35m_ms2dvdk600000gp/T/pip-build-env-niqte0en/overlay/lib/python3.9/site-packages/setuptools/config/pyprojecttoml.py", line 55, in validate
[pipenv.exceptions.InstallError]:           raise ValueError(f"{error}\n{summary}") from None
[pipenv.exceptions.InstallError]:       ValueError: invalid pyproject.toml config: `project`.
[pipenv.exceptions.InstallError]:       configuration error: `project` must contain ['name'] properties
[pipenv.exceptions.InstallError]:       [end of output]
[pipenv.exceptions.InstallError]:   
[pipenv.exceptions.InstallError]:   note: This error originates from a subprocess, and is likely not a problem with pip.
[pipenv.exceptions.InstallError]: error: subprocess-exited-with-error
[pipenv.exceptions.InstallError]: 
[pipenv.exceptions.InstallError]: × Getting requirements to build wheel did not run successfully.
[pipenv.exceptions.InstallError]: │ exit code: 1
[pipenv.exceptions.InstallError]: ╰─> See above for output.
[pipenv.exceptions.InstallError]:
  1. pip3 install -r requirements.txt
    1.尝试使用不同的python3版本创建venv,并尝试同步软件包
    1.尝试手动安装冲突的软件包
zd287kbt

zd287kbt1#

面对同样的问题。只需将版本更新到0.26或0.27,应该会有所帮助

相关问题