-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Pipfile package specifier for different platform not honored #6005
Comments
Its a recent change to sys_markers and os_markers to fold them, but the sdist has to be able to build on the locking platform -- if it cannot be built you can translate those markers directly to the markers key and it will skip trying to install/fold the sub-dependencies of that package. |
Sorry -- wrong thread on that last message. (so i deleted it) the message from 3 hours ago is relevant though. |
Thanks @matteius |
@jtmoon79 certainly, instead of: |
Thanks @matteius ! |
Issue description
Specifier
platform_system
andsys_platform
is not respected duringpipenv update
.On Ubuntu 22, I have a
Pipfile
that has a package that is Windows only (py2exe
). I add specifierplatform_system = "== 'Windows'"
(also triedsys_platform = "== 'win32'"
). However,pipenv update
fails withERROR:pip.subprocessor:python setup.py egg_info exited with 1
(and then more errors). It appears to attempt to build or install the Windows only packagepy2exe
.Package
py2exe
will fail to install on a Linux system (expected)Expected result
pipenv update
will not try to download or build or install a package that has specifiers against it's use.Actual result
pipenv update
downloads and builds a package that it should not.Steps to replicate
Pipfile
Pipfile
package declaration follows the example used in the current docssetuptools
version68.2.2
,pip
version23.3.1
,wheel
version0.41.3
pipenv
2023.10.24
pipenv update
Pipfile
, comment the line with the packagepy2exe
(so the line is ignored) thenpipenv update
will succeedI only tested this apparent bug with the following specifiers:
py2exe = { version = "*", platform_system = "== 'Windows'"}
py2exe = { version = "*", sys_platform = "== 'win32'"}
$ pipenv --support
Pipenv version:
'2023.10.24'
Pipenv location:
'/tmp/a/.venv/lib/python3.10/site-packages/pipenv'
Python location:
'/tmp/a/.venv/bin/python'
OS Name:
'posix'
User pip version:
'23.3.1'
user Python installations found:
PEP 508 Information:
System environment variables:
SHELL
WSL2_GUI_APPS_ENABLED
WSL_DISTRO_NAME
WT_SESSION
PIPENV_ACTIVE
NAME
PWD
LOGNAME
PIP_PYTHON_PATH
HOME
LANG
WSL_INTEROP
LS_COLORS
VIRTUAL_ENV
WAYLAND_DISPLAY
LESSCLOSE
TERM
LESSOPEN
USER
PIP_DISABLE_PIP_VERSION_CHECK
DISPLAY
SHLVL
VIRTUAL_ENV_PROMPT
PYTHONDONTWRITEBYTECODE
XDG_RUNTIME_DIR
PS1
WSLENV
LOCALE
LC_ALL
GCC_COLORS
XDG_DATA_DIRS
PATH
HISTFILESIZE
HOSTTYPE
PULSE_SERVER
WT_PROFILE_ID
SSH_AUTH_SOCKD
OLDPWD
_
PYTHONFINDER_IGNORE_UNSUPPORTED
Pipenv–specific environment variables:
PIPENV_ACTIVE
:1
Debug–specific environment variables:
PATH
:...
SHELL
:/bin/bash
LANG
:en_US.UTF-8
PWD
:/tmp/a
VIRTUAL_ENV
:/tmp/a/.venv
Contents of
Pipfile
('/tmp/a/Pipfile'):Contents of
Pipfile.lock
('/tmp/a/Pipfile.lock'):The text was updated successfully, but these errors were encountered: