Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to install in Poetry 1.7.1 #317

Open
drjct opened this issue Dec 2, 2023 · 2 comments
Open

Unable to install in Poetry 1.7.1 #317

drjct opened this issue Dec 2, 2023 · 2 comments

Comments

@drjct
Copy link

drjct commented Dec 2, 2023

I started a fresh repo and I'm using poetry to install ruptures. There are no other dependencies, just ruptures.

MacOS 14.1
Python = 3.9.12
poetry = 1.7.1

Here's the traceback:

➜ poetry add ruptures    
Using version ^1.1.8 for ruptures

Updating dependencies
Resolving dependencies... (0.1s)

Package operations: 3 installs, 0 updates, 0 removals

  • Installing numpy (1.26.2)
  • Installing scipy (1.11.4)
  • Installing ruptures (1.1.8): Failed

  OverrideNeeded

  ({Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.22.2)>}}, {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.21.0)>}}, {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.19.3)>}}, {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.25.0)>}}, {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.23.3)>}}, {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (<empty>)>}})

  at ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/puzzle/provider.py:660 in complete_package
      656│                     current_overrides.update({dependency_package: package_overrides})
      657│                     overrides.append(current_overrides)
      658│ 
      659│             if overrides:
    → 660│                 raise OverrideNeeded(*overrides)
      661│ 
      662│         # Modifying dependencies as needed
      663│         clean_dependencies = []
      664│         for dep in dependencies:

The following error occurred when trying to handle this error:


  OverrideNeeded

  {Package('oldest-supported-numpy', '2023.10.25'): {'numpy': <Dependency numpy (==1.21.0)>}, Package('oldest-supported-numpy', '2023.8.3'): {'numpy': <Dependency numpy (==1.21.0)>}}

  at ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/puzzle/provider.py:660 in complete_package
      656│                     current_overrides.update({dependency_package: package_overrides})
      657│                     overrides.append(current_overrides)
      658│ 
      659│             if overrides:
    → 660│                 raise OverrideNeeded(*overrides)
      661│ 
      662│         # Modifying dependencies as needed
      663│         clean_dependencies = []
      664│         for dep in dependencies:

The following error occurred when trying to handle this error:


  IncompatibleConstraintsError

  Incompatible constraints in requirements of oldest-supported-numpy (2022.11.19):
  numpy (==1.22.2) ; platform_machine == "loongarch64" and python_version < "3.11"
  numpy (==1.23.3) ; python_version == "3.9" and platform_system == "OS400"
  numpy ; python_version >= "3.9" and platform_python_implementation == "PyPy"

  at ~/.local/pipx/venvs/poetry/lib/python3.9/site-packages/poetry/puzzle/provider.py:920 in _resolve_overlapping_markers
      916│                     specific_source_dependency = dep
      917│                 constraint = constraint.intersect(dep.constraint)
      918│             if constraint.is_empty():
      919│                 # conflict in overlapping area
    → 920│                 raise IncompatibleConstraintsError(package, *used_dependencies)
      921│ 
      922│             if not any(uses):
      923│                 # This is an edge case where the dependency is not required
      924│                 # for the resulting marker. However, we have to consider it anyway

Cannot install ruptures.

TOML file (doesn't have ruptures since it failed on poetry add ruptures

[tool.poetry]
name = "test-project"
version = "0.1.0"
description = ""
authors = ["test author"]

[tool.poetry.dependencies]
python = "^3.9"

[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"

Current (undesirable) workaround: pip install ruptures first then poetry add ruptures works.

@oboulant
Copy link
Collaborator

oboulant commented Dec 4, 2023

When you run pip install ruptures, which version of numpy does it install ?

@drjct
Copy link
Author

drjct commented Dec 4, 2023

numpy 1.26.2

➜ pip list            
Package    Version
---------- -------
numpy      1.26.2
pip        23.3.1
ruptures   1.1.8
scipy      1.11.4
setuptools 68.2.2

@zhenyakovalyov
Copy link

zhenyakovalyov commented Jan 8, 2024

heya @drjct,

  • just tried to install ruptures with (poetry 1.7.1, python 3.12.1, macOS 14.2.1), all good.
  • also works with [email protected]_1
❯ pip list
Package  Version
-------- -------
numpy    1.26.3
pip      23.2.1
ruptures 1.1.9
scipy    1.11.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants