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

Pipenv doesn't install sub-dependencies correctly #2234

Closed
flbraun opened this issue May 21, 2018 · 3 comments
Closed

Pipenv doesn't install sub-dependencies correctly #2234

flbraun opened this issue May 21, 2018 · 3 comments

Comments

@flbraun
Copy link

flbraun commented May 21, 2018

Pipenv doesn't resolve and install all dependencies of packages in my Pipfile. They also don't appear in the lock file. Recreating the lockfile and starting with a new env doesn't help it either.

See output of pipenv.help in "Steps to reproduce".


Expected result

All sub-dependencies are installed correctly.

Actual result

pipenv graph outputs many question marks. pipenv run pip freeze confirms that the dependency packages have not been installed.

Steps to replicate
$ python -m pipenv.help output

Pipenv version: '2018.05.18'

Pipenv location: '/usr/local/lib/python3.6/dist-packages/pipenv'

Python location: '/usr/bin/python3'

Other Python installations in PATH:

  • 2.7: /usr/bin/python2.7

  • 2.7: /usr/bin/python2.7

  • 3.6: /usr/bin/python3.6m

  • 3.6: /usr/bin/python3.6

  • 2.7.14: /usr/bin/python

  • 2.7.14: /usr/bin/python2

  • 3.6.3: /usr/bin/python3

PEP 508 Information:

{'implementation_name': 'cpython',
 'implementation_version': '3.6.3',
 'os_name': 'posix',
 'platform_machine': 'x86_64',
 'platform_python_implementation': 'CPython',
 'platform_release': '4.13.0-41-generic',
 'platform_system': 'Linux',
 'platform_version': '#46-Ubuntu SMP Wed May 2 13:38:30 UTC 2018',
 'python_full_version': '3.6.3',
 'python_version': '3.6',
 'sys_platform': 'linux'}

System environment variables:

  • GS_LIB
  • KDE_FULL_SESSION
  • LS_COLORS
  • LC_MEASUREMENT
  • LESSCLOSE
  • LC_PAPER
  • LC_MONETARY
  • LANG
  • DISPLAY
  • XDG_VTNR
  • PAM_KWALLET5_LOGIN
  • QT_QUICK_CONTROLS_STYLE
  • SSH_AUTH_SOCK
  • MANDATORY_PATH
  • LC_NAME
  • XDG_SESSION_ID
  • USER
  • DESKTOP_SESSION
  • DEFAULTS_PATH
  • PWD
  • HOME
  • GUAKE_TAB_UUID
  • SSH_AGENT_PID
  • QT_ACCESSIBILITY
  • XDG_SESSION_TYPE
  • XDG_DATA_DIRS
  • XDG_SESSION_DESKTOP
  • LC_ADDRESS
  • LC_NUMERIC
  • GTK_MODULES
  • TERM
  • SHELL
  • XDG_SESSION_CLASS
  • XDG_SEAT_PATH
  • XCURSOR_THEME
  • XDG_CURRENT_DESKTOP
  • XDG_SEAT
  • SHLVL
  • LC_TELEPHONE
  • LOGNAME
  • DBUS_SESSION_BUS_ADDRESS
  • XDG_RUNTIME_DIR
  • PAM_KWALLET_LOGIN
  • XAUTHORITY
  • XDG_SESSION_PATH
  • QT_AUTO_SCREEN_SCALE_FACTOR
  • XDG_CONFIG_DIRS
  • PATH
  • LC_IDENTIFICATION
  • KDE_SESSION_UID
  • KDE_SESSION_VERSION
  • SESSION_MANAGER
  • LESSOPEN
  • LC_TIME
  • OLDPWD
  • _
  • PYTHONDONTWRITEBYTECODE
  • PIP_PYTHON_PATH

Pipenv–specific environment variables:

Debug–specific environment variables:

  • PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/chiron/.local/bin
  • SHELL: /bin/bash
  • LANG: en_US.UTF-8
  • PWD: /home/chiron/Documents/test

Contents of Pipfile ('/home/chiron/Documents/test/Pipfile'):

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

[packages]
django = "*"
django-jinja = "*"
django-money = "*"
django-stronghold = "*"
django-crispy-forms = "*"
django-extensions = "*"
feedparser = "*"
django-lifecycle = "*"

[dev-packages]
django-debug-toolbar = "*"
jupyter = "*"

[requires]
python_version = "3.6"

Contents of Pipfile.lock ('/home/chiron/Documents/test/Pipfile.lock'):

{
    "_meta": {
        "hash": {
            "sha256": "8b0d0305d99903082a1cb4545c7d18b5972a398333b8a0eb75749d4c586a553e"
        },
        "pipfile-spec": 6,
        "requires": {
            "python_version": "3.6"
        },
        "sources": [
            {
                "name": "pypi",
                "url": "https://pypi.python.org/simple",
                "verify_ssl": true
            }
        ]
    },
    "default": {
        "django": {
            "hashes": [
                "sha256:26b34f4417aa38d895b6b5307177b51bc3f4d53179d8696a5c19dcb50582523c",
                "sha256:71d1a584bb4ad2b4f933d07d02c716755c1394feaac1ce61ce37843ac5401092"
            ],
            "index": "pypi",
            "version": "==2.0.5"
        },
        "django-crispy-forms": {
            "hashes": [
                "sha256:5952bab971110d0b86c278132dae0aa095beee8f723e625c3d3fa28888f1675f",
                "sha256:705ededc554ad8736157c666681165fe22ead2dec0d5446d65fc9dd976a5a876"
            ],
            "index": "pypi",
            "version": "==1.7.2"
        },
        "django-extensions": {
            "hashes": [
                "sha256:3be3debf53c77ca795bdf713726c923aa3c3f895e1a42e2e31a68c1a562346a4",
                "sha256:94bfac99eb262c5ac27e53eda96925e2e53fe0b331af7dde37012d07639a649c"
            ],
            "index": "pypi",
            "version": "==2.0.7"
        },
        "django-jinja": {
            "hashes": [
                "sha256:8a49d73de616a12075eee14c6d3bbab936261a463457d40348d8b8e2995cfbed",
                "sha256:ceaa0eeebc4d91a5800967e50f4f087f0b6457503e3c2af85dc199bed8732a9a"
            ],
            "index": "pypi",
            "version": "==2.4.1"
        },
        "django-lifecycle": {
            "hashes": [
                "sha256:6372f6850951e1ccaddb50b741020ff5ff2230b50e18e25fded5bf2dd9cdef2e"
            ],
            "index": "pypi",
            "version": "==0.3.0"
        },
        "django-money": {
            "hashes": [
                "sha256:084b3b67e411005c2d6aca9af3d17e5d0debba71b6c1d25b569b12ab70a3ab3b",
                "sha256:975c9910583da105211dcfa80abaf3109d44390a880c98d3f8640307ae67c864"
            ],
            "index": "pypi",
            "version": "==0.13.5"
        },
        "django-stronghold": {
            "hashes": [
                "sha256:9ffb2d5d61945b67061c60a39ec740a9670dda89d96b3c7ef890c1a1a08fd18a"
            ],
            "index": "pypi",
            "version": "==0.3.0"
        },
        "feedparser": {
            "hashes": [
                "sha256:bd030652c2d08532c034c27fcd7c85868e7fa3cb2b17f230a44a6bbc92519bf9",
                "sha256:cd2485472e41471632ed3029d44033ee420ad0b57111db95c240c9160a85831c",
                "sha256:ce875495c90ebd74b179855449040003a1beb40cd13d5f037a0654251e260b02"
            ],
            "index": "pypi",
            "version": "==5.2.1"
        },
        "py-moneyed": {
            "hashes": [
                "sha256:0c5dc04f77f1e0a123df051cc6ddc79267a48c612cb2d3dcfe7eb88cfc395bf9",
                "sha256:f8c04183fd65d307a4b59f4a68332d3b9418d668b2a36cedd531f9cd1eb98933"
            ],
            "version": "==0.7.0"
        },
        "pytz": {
            "hashes": [
                "sha256:65ae0c8101309c45772196b21b74c46b2e5d11b6275c45d251b150d5da334555",
                "sha256:c06425302f2cf668f1bba7a0a03f3c1d34d4ebeef2c72003da308b3947c7f749"
            ],
            "version": "==2018.4"
        },
        "six": {
            "hashes": [
                "sha256:70e8a77beed4562e7f14fe23a786b54f6296e34344c23bc42f07b15018ff98e9",
                "sha256:832dc0e10feb1aa2c68dcc57dbb658f1c7e65b9b61af69048abc87a2db00a0eb"
            ],
            "version": "==1.11.0"
        }
    },
    "develop": {
        "django-debug-toolbar": {
            "hashes": [
                "sha256:4af2a4e1e932dadbda197b18585962d4fc20172b4e5a479490bc659fe998864d",
                "sha256:d9ea75659f76d8f1e3eb8f390b47fc5bad0908d949c34a8a3c4c87978eb40a0f"
            ],
            "index": "pypi",
            "version": "==1.9.1"
        },
        "jupyter": {
            "hashes": [
                "sha256:3e1f86076bbb7c8c207829390305a2b1fe836d471ed54be66a3b8c41e7f46cc7",
                "sha256:5b290f93b98ffbc21c0c7e749f054b3267782166d72fa5e3ed1ed4eaf34a2b78",
                "sha256:d9dc4b3318f310e34c82951ea5d6683f67bed7def4b259fafbfe4f1beb1d8e5f"
            ],
            "index": "pypi",
            "version": "==1.0.0"
        }
    }
}

Create env, lock and install dependencies:

chiron@chiron-pc:~/Documents/test$ pipenv install --dev
Creating a virtualenv for this project…
Using /usr/bin/python3.6m (3.6.3) to create virtualenv…
⠋Running virtualenv with interpreter /usr/bin/python3.6m
Using base prefix '/usr'
New python executable in /home/chiron/.local/share/virtualenvs/test-SmQh7QZk/bin/python3.6m
Also creating executable in /home/chiron/.local/share/virtualenvs/test-SmQh7QZk/bin/python
Installing setuptools, pkg_resources, pip, wheel...done.

Virtualenv location: /home/chiron/.local/share/virtualenvs/test-SmQh7QZk
Pipfile.lock not found, creating…
Locking [dev-packages] dependencies…
Locking [packages] dependencies…
Updated Pipfile.lock (6a553e)!
Installing dependencies from Pipfile.lock (6a553e)…
  🐍   ▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉ 13/13 — 00:00:09
To activate this project's virtualenv, run the following:
 $ pipenv shell

Inspect what happened:

chiron@chiron-pc:~/Documents/test$ pipenv graph
django-crispy-forms==1.7.2
django-debug-toolbar==1.9.1
  - Django [required: >=1.8, installed: 2.0.5]
    - pytz [required: Any, installed: 2018.4]
  - sqlparse [required: >=0.2.0, installed: ?]
django-extensions==2.0.7
  - six [required: >=1.2, installed: 1.11.0]
django-jinja==2.4.1
  - django [required: >=1.8, installed: 2.0.5]
    - pytz [required: Any, installed: 2018.4]
  - jinja2 [required: >=2.5, installed: 2.9.5]
django-lifecycle==0.3.0
django-money==0.13.5
  - Django [required: >=1.8, installed: 2.0.5]
    - pytz [required: Any, installed: 2018.4]
  - py-moneyed [required: >=0.7, installed: 0.7.0]
  - setuptools [required: Any, installed: 39.2.0]
django-stronghold==0.3.0
feedparser==5.2.1
jupyter==1.0.0
  - ipykernel [required: Any, installed: ?]
  - ipywidgets [required: Any, installed: ?]
  - jupyter-console [required: Any, installed: ?]
  - nbconvert [required: Any, installed: ?]
  - notebook [required: Any, installed: ?]
  - qtconsole [required: Any, installed: ?]
pkg-resources==0.0.0

chiron@chiron-pc:~/Documents/test$ pipenv run pip freeze
Django==2.0.5
django-crispy-forms==1.7.2
django-debug-toolbar==1.9.1
django-extensions==2.0.7
django-jinja==2.4.1
django-lifecycle==0.3.0
django-money==0.13.5
django-stronghold==0.3.0
feedparser==5.2.1
jupyter==1.0.0
pkg-resources==0.0.0
py-moneyed==0.7.0
pytz==2018.4
six==1.11.0
@uranusjr
Copy link
Member

All missing packages are from dev-packages. I wonder if this is relevant, or simply a coincidence.

@flbraun
Copy link
Author

flbraun commented May 22, 2018

Just gave it a quick try and moved django-debug-toolbar and jupyter up to [packages] and it's still the same result.

Tested this on a completely different machine, so this issue is definitely reproducible.

techalchemy added a commit that referenced this issue May 26, 2018
- Fixes #2088, #2234, #1901
- Fully leverage piptools' compile functionality by using constraints
  in the same `RequirementSet` during resolution
- Use `PIP_PYTHON_PATH` for compatibility check to filter out
  `requires_python` markers
- Fix vcs resolution
- Update JSON API endpoints
- Enhance resolution for editable dependencies
- Minor fix for adding packages to pipfiles

Signed-off-by: Dan Ryan <dan@danryan.co>
techalchemy added a commit that referenced this issue May 26, 2018
- Fixes #2088, #2234, #1901
- Fully leverage piptools' compile functionality by using constraints
  in the same `RequirementSet` during resolution
- Use `PIP_PYTHON_PATH` for compatibility check to filter out
  `requires_python` markers
- Fix vcs resolution
- Update JSON API endpoints
- Enhance resolution for editable dependencies
- Minor fix for adding packages to pipfiles

Signed-off-by: Dan Ryan <dan@danryan.co>
techalchemy added a commit that referenced this issue May 27, 2018
- Fixes #2088, #2234, #1901
- Fully leverage piptools' compile functionality by using constraints
  in the same `RequirementSet` during resolution
- Use `PIP_PYTHON_PATH` for compatibility check to filter out
  `requires_python` markers
- Fix vcs resolution
- Update JSON API endpoints
- Enhance resolution for editable dependencies
- Minor fix for adding packages to pipfiles

Signed-off-by: Dan Ryan <dan@danryan.co>
@techalchemy
Copy link
Member

This is resolved in master, releasing soon --- sorry for the bugs and thank you for your patience 🍰

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