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

Dependencies could not be resolved #2002

Closed
jamesstidard opened this issue Apr 16, 2018 · 7 comments
Closed

Dependencies could not be resolved #2002

jamesstidard opened this issue Apr 16, 2018 · 7 comments

Comments

@jamesstidard
Copy link
Contributor

Be sure to check the existing issues (both open and closed!).

I've been using sanic-cors via pipenv and I've been getting a dependancy resolution error. My thoughts are because the version identifiers contain the string "dev", though I thought python version parsing did allow for that.

I've opened a main ticket here, but would appreciate any help resolving it. This install did work a couple days ago (maybe yesterday) and it doesn't look like the requirements for that dependancy have changed. So it may aldo be related to the pip 10 release.

Please run $ python -m pipenv.help, and paste the results here.

I actually get error from this. I'm using pipsi to install pipenv globally. I activated the pipenv virtual environment created by pipsi to fun this.

<details><summary>$ python -m pipenv.help output</summary>

Pipenv version: `'11.10.0'`

Pipenv location: `'/Users/james/.local/share/virtualenvs/pipenv/lib/python3.6/site-packages/pipenv'`

Python location: `'/Users/james/.local/share/virtualenvs/pipenv/bin/python'`

Other Python installations in `PATH`:

Traceback (most recent call last):
  File "/Users/james/.pyenv/versions/3.6.5/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/Users/james/.pyenv/versions/3.6.5/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/Users/james/.local/share/virtualenvs/pipenv/lib/python3.6/site-packages/pipenv/help.py", line 89, in <module>
    main()
  File "/Users/james/.local/share/virtualenvs/pipenv/lib/python3.6/site-packages/pipenv/help.py", line 24, in main
    found = find_python_in_path(python_v)
  File "/Users/james/.local/share/virtualenvs/pipenv/lib/python3.6/site-packages/pipenv/core.py", line 355, in find_python_in_path
    version = python_version(p)
  File "/Users/james/.local/share/virtualenvs/pipenv/lib/python3.6/site-packages/pipenv/utils.py", line 218, in python_version
    return u'{major}.{minor}.{micro}'.format(**version)
TypeError: format() argument after ** must be a mapping, not NoneType

Expected result

I install sanic_cors.

Actual result
(Testing-miRSgagl) ↪ pipenv install sanic_cors --verbose
Installing sanic_cors…
⠋Installing 'sanic_cors'
$ "/Users/james/.local/share/virtualenvs/Testing-miRSgagl/bin/pip" install   --verbose    "sanic_cors" -i https://pypi.python.org/simple --exists-action w
Created temporary directory: /private/var/folders/0p/ljj7lrds2gb6tpg5gjpnhbbr0000gn/T/pip-ephem-wheel-cache-5ztw4xbt
Created temporary directory: /private/var/folders/0p/ljj7lrds2gb6tpg5gjpnhbbr0000gn/T/pip-install-4nwl7uxj
Requirement already satisfied: sanic_cors in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (0.9.3)
Requirement already satisfied: sanic>=0.7.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.7.0)
Requirement already satisfied: sanic-plugins-framework>=0.5.0.dev20171225 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.5.2.dev20180201)
Requirement already satisfied: uvloop>=0.5.3 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.9.1)
Requirement already satisfied: ujson>=1.35 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (1.35)
Requirement already satisfied: websockets>=4.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (4.0.1)
Requirement already satisfied: httptools>=0.0.9 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.0.11)
Requirement already satisfied: aiofiles>=0.3.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.3.2)
Cleaning up...

Adding sanic_cors to Pipfile's [packages]…
Pipfile.lock not found, creating…
Locking [dev-packages] dependencies…
Using pip: -i https://pypi.python.org/simple

                          ROUND 1
Current constraints:

Finding the best candidates:

Finding secondary dependencies:
------------------------------------------------------------
Result of round 1: stable, done

Locking [packages] dependencies…
Using pip: -i https://pypi.python.org/simple

                          ROUND 1
Current constraints:
  sanic-cors

Finding the best candidates:
  found candidate sanic-cors==0.9.3 (constraint was <any>)

Finding secondary dependencies:
  sanic-cors==0.9.3         requires sanic-plugins-framework>=0.5.0.dev20171225, sanic>=0.7.0

New dependencies found in this round:
  adding ['sanic', '>=0.7.0', '[]']
  adding ['sanic-plugins-framework', '>=0.5.0.dev20171225', '[]']
Removed dependencies in this round:
Unsafe dependencies in this round:
------------------------------------------------------------
Result of round 1: not stable

                          ROUND 2
Current constraints:
  sanic>=0.7.0
  sanic-cors
  sanic-plugins-framework>=0.5.0.dev20171225

Finding the best candidates:
  found candidate sanic==0.7.0 (constraint was >=0.7.0)
  found candidate sanic-cors==0.9.3 (constraint was <any>)
Using pip: -i https://pypi.python.org/simple

                          ROUND 1
Current constraints:
  sanic-cors

Finding the best candidates:
  found candidate sanic-cors==0.9.3 (constraint was <any>)

Finding secondary dependencies:
  sanic-cors==0.9.3         requires sanic-plugins-framework>=0.5.0.dev20171225, sanic>=0.7.0

New dependencies found in this round:
  adding ['sanic', '>=0.7.0', '[]']
  adding ['sanic-plugins-framework', '>=0.5.0.dev20171225', '[]']
Removed dependencies in this round:
Unsafe dependencies in this round:
------------------------------------------------------------
Result of round 1: not stable

                          ROUND 2
Current constraints:
  sanic>=0.7.0
  sanic-cors
  sanic-plugins-framework>=0.5.0.dev20171225

Finding the best candidates:
  found candidate sanic==0.7.0 (constraint was >=0.7.0)
  found candidate sanic-cors==0.9.3 (constraint was <any>)

Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies.
  You can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation.
Could not find a version that matches sanic-plugins-framework>=0.5.0.dev20171225
Tried: 0.2.0.dev20171102, 0.2.0.dev20171102, 0.3.0.dev20171102, 0.3.0.dev20171102, 0.3.1.dev20171102, 0.3.1.dev20171102, 0.3.2.dev20171102, 0.3.2.dev20171102, 0.3.3.dev20171102, 0.3.3.dev20171102, 0.4.0.dev20171103, 0.4.0.dev20171103, 0.4.1.dev20171103, 0.4.1.dev20171103, 0.4.2.dev20171106, 0.4.2.dev20171106, 0.4.4.dev20171107, 0.4.4.dev20171107, 0.4.5.dev20171113, 0.4.5.dev20171113, 0.5.0.dev20171225, 0.5.0.dev20171225, 0.5.2.dev20180201, 0.5.2.dev20180201
Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies.
  You can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation.
Could not find a version that matches sanic-plugins-framework>=0.5.0.dev20171225
Tried: 0.2.0.dev20171102, 0.2.0.dev20171102, 0.3.0.dev20171102, 0.3.0.dev20171102, 0.3.1.dev20171102, 0.3.1.dev20171102, 0.3.2.dev20171102, 0.3.2.dev20171102, 0.3.3.dev20171102, 0.3.3.dev20171102, 0.4.0.dev20171103, 0.4.0.dev20171103, 0.4.1.dev20171103, 0.4.1.dev20171103, 0.4.2.dev20171106, 0.4.2.dev20171106, 0.4.4.dev20171107, 0.4.4.dev20171107, 0.4.5.dev20171113, 0.4.5.dev20171113, 0.5.0.dev20171225, 0.5.0.dev20171225, 0.5.2.dev20180201, 0.5.2.dev20180201
Steps to replicate

Provide the steps to replicate (which usually at least includes the commands and the Pipfile).

$ mkdir testing
$ cd testing/
$ pipenv install sanic_cors

Here are the outputs from a --skip-lock and graph, as prompted to do in the terminal.

(Testing-miRSgagl) ↪ pipenv install sanic_cors --skip-lock
Installing sanic_cors…
Requirement already satisfied: sanic_cors in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (0.9.3)
Requirement already satisfied: sanic-plugins-framework>=0.5.0.dev20171225 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.5.2.dev20180201)
Requirement already satisfied: sanic>=0.7.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.7.0)
Requirement already satisfied: uvloop>=0.5.3 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.9.1)
Requirement already satisfied: httptools>=0.0.9 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.0.11)
Requirement already satisfied: ujson>=1.35 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (1.35)
Requirement already satisfied: aiofiles>=0.3.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.3.2)
Requirement already satisfied: websockets>=4.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (4.0.1)
Sanic-Cors==0.9.3
  - sanic [required: >=0.7.0, installed: 0.7.0]
    - aiofiles [required: >=0.3.0, installed: 0.3.2]
    - httptools [required: >=0.0.9, installed: 0.0.11]
    - ujson [required: >=1.35, installed: 1.35]
    - uvloop [required: >=0.5.3, installed: 0.9.1]
    - websockets [required: >=4.0, installed: 4.0.1]
  - sanic-plugins-framework [required: >=0.5.0.dev20171225, installed: 0.5.2.dev20180201]
    - sanic [required: >=0.7.0, installed: 0.7.0]
      - aiofiles [required: >=0.3.0, installed: 0.3.2]
      - httptools [required: >=0.0.9, installed: 0.0.11]
      - ujson [required: >=1.35, installed: 1.35]
      - uvloop [required: >=0.5.3, installed: 0.9.1]
      - websockets [required: >=4.0, installed: 4.0.1]

Thank you and sorry for the mammoth amounts of output lines.

@techalchemy
Copy link
Member

This is a known bug in the current release of pipenv. Releasing a bug fix later but you can try from master if you like and let us know if it works

@Wave-Venture-Build
Copy link

@techalchemy I did have a look through the open issues and thought it could have been related to a few of them. Thanks for the heads up.

@techalchemy
Copy link
Member

If that doesn’t work do let me know so we can sort this out before we release

@jamesstidard
Copy link
Contributor Author

I believe I just installed from master and I do still get the same issue:

james at freebie in ~/D/Testing
(Testing-miRSgagl) ↪ pip install git+https://github.com/pypa/pipenv@master#egg=pipenv
Collecting pipenv from git+https://github.com/pypa/pipenv@master#egg=pipenv
  Cloning https://github.com/pypa/pipenv (to revision master) to /private/var/folders/0p/ljj7lrds2gb6tpg5gjpnhbbr0000gn/T/pip-install-ule2tnzp/pipenv
Requirement already satisfied: pip>=9.0.1 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from pipenv) (10.0.0)
Requirement already satisfied: certifi in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from pipenv) (2018.1.18)
Requirement already satisfied: setuptools>=36.2.1 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from pipenv) (39.0.1)
Requirement already satisfied: virtualenv-clone>=0.2.5 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from pipenv) (0.3.0)
Requirement already satisfied: virtualenv in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from pipenv) (15.2.0)
Building wheels for collected packages: pipenv
  Running setup.py bdist_wheel for pipenv ... done
  Stored in directory: /private/var/folders/0p/ljj7lrds2gb6tpg5gjpnhbbr0000gn/T/pip-ephem-wheel-cache-6m2l48ks/wheels/e9/22/21/4f1fe6a6f3d5f0fe3efda1cca02b4b03ff08a6395c62983c75
Successfully built pipenv
Installing collected packages: pipenv
Successfully installed pipenv-11.10.0
james at freebie in ~/D/Testing
(Testing-miRSgagl) ↪ which pipenv
/Users/james/.local/share/virtualenvs/Testing-miRSgagl/bin/pipenv
james at freebie in ~/D/Testing
(Testing-miRSgagl) ↪ pipenv install sanic_cors
Installing sanic_cors…
Requirement already satisfied: sanic_cors in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (0.9.3)
Requirement already satisfied: sanic-plugins-framework>=0.5.0.dev20171225 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.5.2.dev20180201)
Requirement already satisfied: sanic>=0.7.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic_cors) (0.7.0)
Requirement already satisfied: aiofiles>=0.3.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.3.2)
Requirement already satisfied: ujson>=1.35 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (1.35)
Requirement already satisfied: websockets>=4.0 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (4.0.1)
Requirement already satisfied: httptools>=0.0.9 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.0.11)
Requirement already satisfied: uvloop>=0.5.3 in /Users/james/.local/share/virtualenvs/Testing-miRSgagl/lib/python3.6/site-packages (from sanic>=0.7.0->sanic_cors) (0.9.1)

Adding sanic_cors to Pipfile's [packages]…
Pipfile.lock (fbb70d) out of date, updating to (69707f)…
Locking [dev-packages] dependencies…
Locking [packages] dependencies…

Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies.
  You can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation.
Could not find a version that matches sanic-plugins-framework>=0.5.0.dev20171225
Tried: 0.2.0.dev20171102, 0.2.0.dev20171102, 0.3.0.dev20171102, 0.3.0.dev20171102, 0.3.1.dev20171102, 0.3.1.dev20171102, 0.3.2.dev20171102, 0.3.2.dev20171102, 0.3.3.dev20171102, 0.3.3.dev20171102, 0.4.0.dev20171103, 0.4.0.dev20171103, 0.4.1.dev20171103, 0.4.1.dev20171103, 0.4.2.dev20171106, 0.4.2.dev20171106, 0.4.4.dev20171107, 0.4.4.dev20171107, 0.4.5.dev20171113, 0.4.5.dev20171113, 0.5.0.dev20171225, 0.5.0.dev20171225, 0.5.2.dev20180201, 0.5.2.dev20180201

@techalchemy
Copy link
Member

Use pipenv install —pre or you won’t get prereleases

@jamesstidard
Copy link
Contributor Author

@techalchemy Ah, I thought just installing directly from the repo would have done that, my bad.

Good news by the way, it works again. Thank you for the help. Do you have an idea of the normal release rate? Just so I know if I may as well wait it out or update a number of machines.

@techalchemy
Copy link
Member

Should get something out today as we have a few bug fixes in the pipeline - thanks for the report and the quick responses, glad we sorted this out!

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