question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Incorrect python version checking

See original GitHub issue
  • I am on the latest Poetry version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option).

Issue

I tried to install dependency which uses setuptools and python_requires='>=3.6'. But this seems to be in conflict with python requirement. Of my pyproject.toml.

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

It causes:

poetry update
Updating dependencies
Resolving dependencies... (0.3s)

[SolverProblemError]
The current project's Python requirement (^3.6.0) is not compatible with some of the required packages Python requirement:
  - djangorestframework-simplejwt requires Python >=3.6,<3.9

Because djangorestframework-simplejwt (4.4.0) requires Python >=3.6,<3.9
 and no versions of djangorestframework-simplejwt match >4.4.0,<4.5.0, djangorestframework-simplejwt is forbidden.
So, because permission-service depends on djangorestframework-simplejwt (~4.4.0), version solving failed.
https://gist.github.com/shenek/50cfa373695a917d91ca06873660b965

And I’m using python version 3.7 which should match here.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:6
  • Comments:11 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
shenekcommented, Mar 12, 2020

As a workaround you can:

[tool.poetry.dependencies]
python = ">=3.6,<3.9"
1reaction
ZelphirKaltstahlcommented, Mar 28, 2020

Ah OK, I think that I understand it better now. I would like to add, that this behavior is unusual for anyone having used requirements.txt, pipenv or npm before. Which does not need to be a bad thing. Here is a suggestion: Perhaps we could take this as an example and put it in the readme, somewhere more visible, so that people do not come with different expectations and do not hit this problem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Module or Incorrect Python Version Problem? - Stack Overflow
Check your python version, if it does not work restart your computer and try run setup.py install on the python command line.
Read more >
Python in command line runs the wrong version? - Super User
I have to type in C:\Python27\python.exe every time I want to access the correct version of python I want. What other places can...
Read more >
Incorrect binary version for python3 when using update ...
The problem is that I hoped the update-alternatives to replace python bin with specified path. In the case below I am expecting python...
Read more >
Invalid Syntax in Python: Common Reasons for SyntaxError
Python will attempt to help you determine where the invalid syntax is in your code, but the traceback it provides can be a...
Read more >
Python3.6's Pip Checking wrong Python Version
Install any Python versions you want. Refer to it later with the -n parameter ( python2 or python3 here). Python 2: conda create...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found