python-poetry / poetry

Python packaging and dependency management made easy
https://python-poetry.org
MIT License
31k stars 2.25k forks source link

Package wheels fail to be fetched by Poetry (pyrsistent package) #7294

Closed GytisBraz closed 1 year ago

GytisBraz commented 1 year ago

Issue

Installing dependencies using the above pyproject.toml file fails with:

Finding the necessary packages for the current system

Package operations: 1 install, 0 updates, 0 removals

  • Installing pyrsistent (0.19.3): Pending...
[keyring.backend] Loading KWallet
[keyring.backend] Loading SecretService
[keyring.backend] Loading Windows
[keyring.backend] Loading chainer
[keyring.backend] Loading libsecret
[keyring.backend] Loading macOS
Creating new session for pypi.org
Skipping pyrsistent-0.19.3-cp39-cp39-macosx_10_9_universal2.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3-cp39-cp39-win32.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3-cp39-cp39-win_amd64.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3-py3-none-any.whl as sha256 checksum does not match expected value
Skipping pyrsistent-0.19.3.tar.gz as sha256 checksum does not match expected value
Skipping wheel pyrsistent-0.19.3-cp310-cp310-macosx_10_9_universal2.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp310-cp310-win32.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp310-cp310-win_amd64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp311-cp311-macosx_10_9_universal2.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp311-cp311-win32.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp311-cp311-win_amd64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp37-cp37m-macosx_10_9_x86_64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp37-cp37m-win32.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp37-cp37m-win_amd64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp38-cp38-macosx_10_9_universal2.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp38-cp38-win32.whl as this is not supported by the current environment
Skipping wheel pyrsistent-0.19.3-cp38-cp38-win_amd64.whl as this is not supported by the current environment
  • Installing pyrsistent (0.19.3): Failed

  Stack trace:

  5  ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/executor.py:263 in _execute_operation
      261│ 
      262│             try:
    → 263│                 result = self._do_execute_operation(operation)
      264│             except EnvCommandError as e:
      265│                 if e.e.returncode == -2:

  4  ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/executor.py:334 in _do_execute_operation
      332│             return 0
      333│ 
    → 334│         result: int = getattr(self, f"_execute_{method}")(operation)
      335│ 
      336│         if result != 0:

  3  ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/executor.py:454 in _execute_install
      452│ 
      453│     def _execute_install(self, operation: Install | Update) -> int:
    → 454│         status_code = self._install(operation)
      455│ 
      456│         self._save_url_reference(operation)

  2  ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/executor.py:488 in _install
      486│             archive = self._download_link(operation, Link(package.source_url))
      487│         else:
    → 488│             archive = self._download(operation)
      489│ 
      490│         operation_message = self.get_operation_message(operation)

  1  ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/executor.py:626 in _download
      624│ 
      625│     def _download(self, operation: Install | Update) -> Path:
    → 626│         link = self._chooser.choose_for(operation.package)
      627│ 
      628│         if link.yanked:

  RuntimeError

  Unable to find installation candidates for pyrsistent (0.19.3)

  at ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/installation/chooser.py:105 in choose_for
      101│ 
      102│             links.append(link)
      103│ 
      104│         if not links:
    → 105│             raise RuntimeError(f"Unable to find installation candidates for {package}")
      106│ 
      107│         # Get the best link
      108│         chosen = max(links, key=lambda link: self._sort_key(package, link))
      109│ 

So it seems that the correct wheel could not be fetched by Poetry.

The package can be installed via pip though, with pip install pyrsistent==0.19.3, which succeeds without errors.

dimbleby commented 1 year ago

The error messages are quite clear that distributions are being skipped because sha256 checksum does not match expected value

either

you'll probably need to clear your poetry cache and relock

GytisBraz commented 1 year ago

The error messages are quite clear that distributions are being skipped because sha256 checksum does not match expected value

either

you'll probably need to clear your poetry cache and relock

Thanks, that worked

github-actions[bot] commented 6 months ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.