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

Version requiremnt issues #43

Open
ianhi opened this issue Dec 5, 2022 · 4 comments
Open

Version requiremnt issues #43

ianhi opened this issue Dec 5, 2022 · 4 comments

Comments

@ianhi
Copy link

ianhi commented Dec 5, 2022

After attempting poetry install I'm getting the following errors (with python 3.10)

Updating dependencies
Resolving dependencies... (1.7s)

The current project's Python requirement (>=3.7,<3.12) is not compatible with some of the required packages Python requirement:
  - scipy requires Python >=3.8, so it will not be satisfied for Python >=3.7,<3.8
  - scipy requires Python >=3.8,<3.11, so it will not be satisfied for Python >=3.7,<3.8 || >=3.11,<3.12
  - scipy requires Python >=3.8,<3.11, so it will not be satisfied for Python >=3.7,<3.8 || >=3.11,<3.12
  - scipy requires Python >=3.8,<3.12, so it will not be satisfied for Python >=3.7,<3.8
  - scipy requires Python >=3.8,<3.12, so it will not be satisfied for Python >=3.7,<3.8
  - scipy requires Python >=3.8, so it will not be satisfied for Python >=3.7,<3.8

Because no versions of scipy match >1.8.0,<1.8.1 || >1.8.1,<1.9.0 || >1.9.0,<1.9.1 || >1.9.1,<1.9.2 || >1.9.2,<1.9.3 || >1.9.3
 and scipy (1.8.0) requires Python >=3.8,<3.11, scipy is forbidden.
And because scipy (1.8.1) requires Python >=3.8,<3.11
 and scipy (1.9.0) requires Python >=3.8,<3.12, scipy is forbidden.
And because scipy (1.9.1) requires Python >=3.8,<3.12
 and scipy (1.9.2) requires Python >=3.8, scipy is forbidden.
So, because scipy (1.9.3) requires Python >=3.8
 and jupyter-compare-view depends on scipy (>=1.8.0), version solving failed.

  • Check your dependencies Python requirement: The Python requirement can be specified via the `python` or `markers` properties
    
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.12"
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.11"
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.11"
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.12"
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.12"
    For scipy, a possible solution would be to set the `python` property to ">=3.8,<3.12"

    https://python-poetry.org/docs/dependency-specification/#python-restricted-dependencies,
    https://python-poetry.org/docs/dependency-specification/#using-environment-markers

@kolibril13
Copy link
Member

Thanks for the report.
The latest commit changed some things in the version requirements: #42
and I guess this broke it.
I'll investigate this in a few hours. Till now, working with the pre-last commit should solve the problem.

@kolibril13
Copy link
Member

I've just tried it with python versions 3.7-3.11 and
it works for 3.8,3.9 and 3.10 for me:

3.7

python3.7 -m venv .venv7
source .venv7/bin/activate
poetry install 
deactivate

fails.

(.venv7) jan-hendrik@Jan-Hendriks-MacBook-Air jupyter_compare_view % poetry install

Installing dependencies from lock file
Warning: The lock file is not up to date with the latest changes in pyproject.toml. You may be getting outdated dependencies. Run update to update them.

  SolverProblemError

  The current project's Python requirement (3.7.9) is not compatible with some of the required packages Python requirement:
    - scipy requires Python >=3.8,<3.11, so it will not be satisfied for Python 3.7.9
  
  Because scipy (1.8.1) requires Python >=3.8,<3.11
   and no versions of scipy match >=1.8.0,<1.8.1 || >1.8.1, scipy is forbidden.
  So, because jupyter-compare-view depends on scipy (>=1.8.0), version solving failed.

  at ~/.poetry/lib/poetry/puzzle/solver.py:241 in _solve
      237│             packages = result.packages
      238│         except OverrideNeeded as e:
      239│             return self.solve_in_compatibility_mode(e.overrides, use_latest=use_latest)
      240│         except SolveFailure as e:
    → 241│             raise SolverProblemError(e)
      242│ 
      243│         results = dict(
      244│             depth_first_search(
      245│                 PackageNode(self._package, packages), aggregate_package_nodes

  • Check your dependencies Python requirement: The Python requirement can be specified via the `python` or `markers` properties
    
    For scipy, a possible solution would be to set the `python` property to "<empty>"

    https://python-poetry.org/docs/dependency-specification/#python-restricted-dependencies,
    https://python-poetry.org/docs/dependency-specification/#using-environment-markers

3.8

python3.8 -m venv .venv8
source .venv8/bin/activate
poetry install
deactivate

works.

3.9

python3.9 -m venv .venv9
source .venv9/bin/activate
poetry install
deactivate

works.

3.10

python3.10 -m venv .venv10
source .venv10/bin/activate
poetry install
deactivate

works.

3.11

python3.11 -m venv .venv11
source .venv11/bin/activate
poetry install
deactivate

fails:

(.venv11) jan-hendrik@Jan-Hendriks-MacBook-Air jupyter_compare_view % poetry install

Traceback (most recent call last):
  File "/Users/jan-hendrik/.poetry/bin/poetry", line 17, in <module>
    from poetry.console import main
  File "/Users/jan-hendrik/.poetry/lib/poetry/console/__init__.py", line 1, in <module>
    from .application import Application
  File "/Users/jan-hendrik/.poetry/lib/poetry/console/application.py", line 3, in <module>
    from cleo import Application as BaseApplication
ModuleNotFoundError: No module named 'cleo'
(.venv11) jan-hendrik@Jan-Hendriks-MacBook-Air jupyter_compare_view % 

@amorgun
Copy link
Contributor

amorgun commented Dec 10, 2022

scipy is never actually used so I suggest dropping it from the requirements.

@kolibril13
Copy link
Member

scipy is only in the developer dependencies, as can be seen here:

scipy = ">=1.8.0"

so for users It's not there either way.

and SciPy is needed for scikit-image, which provides the example images.
https://scikit-image.org/docs/stable/install.html#full-requirements-list

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