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

Error when executing pipenv install #1617

Closed
adlermedrado opened this issue Mar 8, 2018 · 15 comments
Closed

Error when executing pipenv install #1617

adlermedrado opened this issue Mar 8, 2018 · 15 comments
Assignees
Labels
Category: Dependency Resolution Issue relates to dependency resolution. Type: Bug 🐛 This issue is a bug.

Comments

@adlermedrado
Copy link

I'm getting an error when trying to run pipenv install

  1. Ubuntu Linux
  2. Python version: Python 3.6.4
  3. Pipenv version: 11.1.5
Expected result

The dependencies install

Actual result
adler@masada:~/devel/project$ pipenv install 
Pipfile.lock not found, creating…
Locking [dev-packages] dependencies…
le "/home/adler/.local/lib/python3.6/site-packages/pipenv/resolver.py", line 19, in resolve
    return pipenv.utils.resolve_deps(packages, which, project=project, pre=pre, sources=sources, clear=clear, verbose=verbose)
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/../pipenv/utils.py", line 392, in resolve_deps
    resolved_tree, resolver = actually_resolve_reps(deps, index_lookup, markers_lookup, project, sources, verbose, clear, pre)
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/../pipenv/utils.py", line 325, in actually_resolve_reps
    resolved_tree.update(resolver.resolve(max_rounds=PIPENV_MAX_ROUNDS))
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/patched/piptools/resolver.py", line 102, in resolve
    has_changed, best_matches = self._resolve_one_round()
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/patched/piptools/resolver.py", line 200, in _resolve_one_round
    for dep in self._iter_dependencies(best_match):
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/patched/piptools/resolver.py", line 310, in _iter_dependencies
    yield InstallRequirement.from_line(dependency_string, constraint=ireq.constraint)
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/patched/pip/req/req_install.py", line 181, in from_line
    markers = Marker(markers)
  File "/home/adler/.local/lib/python3.6/site-packages/pipenv/patched/pip/_vendor/packaging/markers.py", line 282, in __init__
    raise InvalidMarker(err_str)
pip._vendor.packaging.markers.InvalidMarker: Invalid marker: 'python_version in "3.4, 3.5, 3.6"; python_version in "3.4, 3.5, 3.6"', parse error at '; python'
@kennethreitz
Copy link
Contributor

kennethreitz commented Mar 8, 2018

Please provide your Pipfile.

@kennethreitz kennethreitz added Type: Bug 🐛 This issue is a bug. Category: Dependency Resolution Issue relates to dependency resolution. labels Mar 8, 2018
@kennethreitz kennethreitz self-assigned this Mar 8, 2018
@techalchemy
Copy link
Member

If you specified somepackage; python_version in "3.4, 3.5, 3.6"' as a marker, that's not a valid marker and will continue to throw this error

@adlermedrado
Copy link
Author

Hi.

This is the Pipfile.

[[source]]

url = "https://pypi.python.org/simple"
verify_ssl = true
name = "pypi"


[dev-packages]

ipdb = "*"
pre-commit = "*"
pytest-cov = "*"
pytest-django = "*"
vcrpy = "*"
pgcli = "*"


[packages]

belogging = "*"
django = "*"
dj-database-url = "*"
django-cache-url = "*"
django-extensions = "*"
django-widget-tweaks = "*"
django-model-utils = "*"
prettyconf = "*"
"psycopg2" = "*"
unipath = "*"
requests = "*"
pillow = "*"
python-magic = "*"


[requires]

python_version = "3.6"

Thank you.

@notdaniel
Copy link

I am experiencing the same issue. Nothing in my project has changed -- the error is only introduced with pipenv v11.1.4. Reverting to v11.1.3 or earlier solves it for me.

@kennethreitz
Copy link
Contributor

@notdaniel please provide your Pipfile. We can't fix the bug if we can't reproduce it :)

@notdaniel
Copy link

@kennethreitz Apologies. Here is mine:

[[source]]

url = "https://pypi.python.org/simple"
verify_ssl = true
name = "pypi"


[dev-packages]

pylint = "*"
honcho = "*"
yapf = "*"
konch = "*"
ptpython = "*"
rdbtools = "*"
python-lzf = "*"
"autopep8" = "*"


[packages]

aiohttp = "*"
cchardet = "*"
aiodns = "*"
click = "*"
logzero = "*"
python-telegram-bot = "*"
redis = "*"
walrus = "*"
blinker = "*"
pendulum = "*"
requests = "*"
pyrsistent = "*"
ccxt = "*"
boltons = "*"
ujson = "*"
prettyprinter = "*"
crayons = "*"
"delegator.py" = "*"
twitter = "*"
pytest = "*"
python-decouple = "*"


[requires]

python_version = "3.6"


[pipenv]

allow_prereleases = true```

@kennethreitz
Copy link
Contributor

Thank you. I'll work on a fix ASAP. It's been a long day, though — so might not be until tomorrow.

@kennethreitz
Copy link
Contributor

another report: #1622

@techalchemy
Copy link
Member

techalchemy commented Mar 9, 2018

This should be fixed in #1624 -- feel free to try it out and let me know: pip install -e git+https://github.com/pypa/pipenv.git@bugfix/resolver-markers#egg=pipenv

@rosygupta
Copy link

@techalchemy I'm facing this issue in pipenv 11.8.0 version. Can you please confirm if its fixed in it?

@msheiny
Copy link

msheiny commented Mar 19, 2018

@kennethreitz im still hitting this issue in 11.8.3 . Anything else I can provide for debugging?

[[source]]

verify_ssl = true
url = "https://pypi.python.org/simple"
name = "pypi"


[packages]

django-logging-json = {git = "https://github.com/freedomofpress/django-logging.git", ref = "Remove_Elastic", editable = true}
pshtt-dependency-hell = {git = "https://github.com/nabla-c0d3/sslyze.git", ref = "ef357c2e76b6ba66f23db5fb1f95c7e8a6c13b9d", editable = true}
bleach = "*"
django-allauth = "==0.34.0"
django-allauth-2fa = "*"
django-anymail = {extras = ["mailgun"], version = ">=1.4"}
django-modelcluster = "*"
django-recaptcha = "*"
django-settings-export = "*"
django-webpack-loader = "*"
Django = "==1.11.5"
feedparser = "*"
gunicorn = "*"
lxml = "*"
markdown2 = ">=2.3.5"
pshtt = "==0.3.0"
psycopg2 = "*"
Pygments = "*"
unittest-xml-reporting = "*"
wagtail-django-recaptcha = "*"
wagtail-factories = "*"
wagtail-metadata = "*"
wagtail = "<1.13"
zxcvbn-python = "*"


[dev-packages]

factory_boy = "*"
# https://github.com/kevin1024/vcrpy/issues/342
vcrpy = "==1.11.0"

@techalchemy
Copy link
Member

@msheiny see #1791

@msheiny
Copy link

msheiny commented Mar 20, 2018

thanks @techalchemy !! ❤️

@rosygupta
Copy link

@msheiny How does that issue help? I didn't get it.

@techalchemy
Copy link
Member

@rosygupta thought it was fixed, new fix coming

techalchemy added a commit that referenced this issue Mar 20, 2018
- Fix Overlapping naming checking for inner markers
- Perform a first-pass right-side split of markers and remove other
exact matching markers from the dependency string
- Fixes #1617, #1791, #1805, #1622
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: Dependency Resolution Issue relates to dependency resolution. Type: Bug 🐛 This issue is a bug.
Projects
None yet
Development

No branches or pull requests

6 participants