pipenv not creating pip.lock file
See original GitHub issuepipenv supposed to create pipfile and pip.lock file. But when I install a dependency. Pip.lock file isn’t creating. and I get this error message
Locking Failed! [pipenv.exceptions.ResolutionFailure]: File "c:/users/ema/appdata/local/programs/python/python37/lib/site-packages/pipenv/resolver.py", line 69, in resolve [pipenv.exceptions.ResolutionFailure]: req_dir=requirements_dir [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 726, in resolve_deps [pipenv.exceptions.ResolutionFailure]: req_dir=req_dir, [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 480, in actually_resolve_deps [pipenv.exceptions.ResolutionFailure]: resolved_tree = resolver.resolve() [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 395, in resolve [pipenv.exceptions.ResolutionFailure]: raise ResolutionFailure(message=str(e)) [pipenv.exceptions.ResolutionFailure]: pipenv.exceptions.ResolutionFailure: ERROR: ERROR: Could not find a version that matches aniso8601<8.0.0,<=6.0.*,>=3,>=7.0.0 [pipenv.exceptions.ResolutionFailure]: Tried: 0.48, 0.49, 0.50, 0.60, 0.70, 0.80, 0.81, 0.82, 0.83, 0.84, 0.85, 0.90, 0.91, 0.92, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 1.3.0, 2.0.0, 2.0.1, 2.0.1, 3.0.0, 3.0.0, 3.0.2, 3.0.2, 4.0.0, 4.0.0, 4.0.1, 4.0.1, 4.1.0, 4.1.0, 5.0.0, 5.0.0, 5.0.1, 5.0.1, 5.1.0, 5.1.0, 6.0.0, 6.0.0, 7.0.0, 7.0.0 [pipenv.exceptions.ResolutionFailure]: Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies. First try clearing your dependency cache with $ pipenv lock --clear, then try the original command again. Alternatively, you can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation. Hint: try $ pipenv lock --pre if it is a pre-release dependency. ERROR: ERROR: Could not find a version that matches aniso8601<8.0.0,<=6.0.*,>=3,>=7.0.0 Tried: 0.48, 0.49, 0.50, 0.60, 0.70, 0.80, 0.81, 0.82, 0.83, 0.84, 0.85, 0.90, 0.91, 0.92, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 1.3.0, 2.0.0, 2.0.1, 2.0.1, 3.0.0, 3.0.0, 3.0.2, 3.0.2, 4.0.0, 4.0.0, 4.0.1, 4.0.1, 4.1.0, 4.1.0, 5.0.0, 5.0.0, 5.0.1, 5.0.1, 5.1.0, 5.1.0, 6.0.0, 6.0.0, 7.0.0, 7.0.0 There are incompatible versions in the resolved dependencies. [pipenv.exceptions.ResolutionFailure]: req_dir=requirements_dir [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 726, in resolve_deps [pipenv.exceptions.ResolutionFailure]: req_dir=req_dir, [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 480, in actually_resolve_deps [pipenv.exceptions.ResolutionFailure]: resolved_tree = resolver.resolve() [pipenv.exceptions.ResolutionFailure]: File "c:\users\ema\appdata\local\programs\python\python37\lib\site-packages\pipenv\utils.py", line 395, in resolve [pipenv.exceptions.ResolutionFailure]: raise ResolutionFailure(message=str(e)) [pipenv.exceptions.ResolutionFailure]: pipenv.exceptions.ResolutionFailure: ERROR: ERROR: Could not find a version that matches aniso8601<8.0.0,<=6.0.*,>=3,>=7.0.0 [pipenv.exceptions.ResolutionFailure]: Tried: 0.48, 0.49, 0.50, 0.60, 0.70, 0.80, 0.81, 0.82, 0.83, 0.84, 0.85, 0.90, 0.91, 0.92, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 1.3.0, 2.0.0, 2.0.1, 2.0.1, 3.0.0, 3.0.0, 3.0.2, 3.0.2, 4.0.0, 4.0.0, 4.0.1, 4.0.1, 4.1.0, 4.1.0, 5.0.0, 5.0.0, 5.0.1, 5.0.1, 5.1.0, 5.1.0, 6.0.0, 6.0.0, 7.0.0, 7.0.0 [pipenv.exceptions.ResolutionFailure]: Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies. First try clearing your dependency cache with $ pipenv lock --clear, then try the original command again. Alternatively, you can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation. Hint: try $ pipenv lock --pre if it is a pre-release dependency. ERROR: ERROR: Could not find a version that matches aniso8601<8.0.0,<=6.0.*,>=3,>=7.0.0 Tried: 0.48, 0.49, 0.50, 0.60, 0.70, 0.80, 0.81, 0.82, 0.83, 0.84, 0.85, 0.90, 0.91, 0.92, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 1.3.0, 2.0.0, 2.0.1, 2.0.1, 3.0.0, 3.0.0, 3.0.2, 3.0.2, 4.0.0, 4.0.0, 4.0.1, 4.0.1, 4.1.0, 4.1.0, 5.0.0, 5.0.0, 5.0.1, 5.0.1, 5.1.0, 5.1.0, 6.0.0, 6.0.0, 7.0.0, 7.0.0 There are incompatible versions in the resolved dependencies.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:10
Top GitHub Comments
@iNightElf I don’t think, that would help. You would have to get aniso8601 to version 4.* (that one doesn’t require relativetimebuilder), but you wont be simply able to do that.
What could help you (kinda) at least continue development:
aniso8601 = "==5.1.0"
relativetimebuilder = "<2.0.0"
pipenv install --skip-lock
You will get some errors, but all packages will be installed hopefully. Works for me. Of course no locking.
Hope this will help.
Thank you @Kitefiko , I have run into exactly this problem and you saved me some debugging. Based on your diagnosis, I have a workaround: add this line to your Pipfile:
relativetimebuilder = "<2.0.0"
For my particular set of packages, at least, this allowed a Pipfile.lock to be built.It seems like the larger issue is that, even though a set of packages existed to satisfy the dependencies given in a Pipfile, Pipenv’s dependency resolution algorithm backed itself into a corner. I’m guessing that fixing that is a hard problem (apparently dependency resolution in general is an NP-hard problem https://stackoverflow.com/questions/28099683/algorithm-for-dependency-resolution).
Do any of the Pipenv maintainers have some pointers about how to go about taking a crack at this, if one were so inclined?