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
--extra-pip-args
doesn't pick up --platform
option for pip
correclty.
#6001
Comments
took a quick look at the code - seems like this flag isn't passed down to the locking function https://github.com/pypa/pipenv/blob/main/pipenv/routines/install.py#L648-L655 is |
@ChannyClaus I opened a PR that I believe addresses it. #6006 |
hmm does the command above |
Well I wouldn't pass |
yeah i think making it work with the specifier is critical - at least for the use case we have a bunch of apple silicon macbook, i.e.
users working with a |
Well something is wrong with that version for it to be resolved, version specifiers in generally are working. |
Actually my reason it wasn't resolving is I have default python 3.11 and that version only goes up to 3.11 -- when I run this it works:
|
The other thing my PR does not address is how to store extra pip args in the Pipfile for future relocking so it doesn't have to be supplied on the CLI everytime. Also I am pretty sure in my PR i haven't exposed it directly to the lock command yet but that should be easy enough to add. |
hmm something still seems awry on my end (just tried the command that worked for you); maybe i'm doing something wrong? (it seems to be using the correct code based on the stacktrace) |
What other packages in your Pipfile dependencies might be affecting your resolution? maybe something is requiring a newer version of tensorflow. |
Well wait, |
Looks like the wheel you are targeting is [macosx_10_14_x86_64] as you had in your original comment (https://files.pythonhosted.org/packages/b1/c7/0df8a0819e16af0fdd38791dc048af621a089fb952e313206bb9e6fea42d/tensorflow-2.8.3-cp310-cp310-macosx_10_14_x86_64.whl) |
well that was actually kinda why i created this issue - to be able to feed platforms different from my local when installing / locking (our use case is for masquarading x86-64 but the implementation should work for all platforms, i suspect?). for example,
and i was hoping we'd be able to get |
Well you haven't answered my question -- do you have anything else in your Pipfile being specified? I showed an example of it working with my branch, but I had to downgrade from python 3.11 -- however your logs indicate something else in the Pipfile is restricting the resolver to a version of tensorflow higher than what you are installing. Installing it as a 1-off with pip isn't the same check if you have anything else defined in your Pipfile. |
sorry about that. fails the same way in a newly created dir:
|
@ChannyClaus you are still specifying a windows platform in that example. Digging a bit deeper, you have a arm64 architecture, but the 2.8 wheels do not have a mac os arm wheel (just x86 as I am not quite sure why it wouldn't fail with the pip example, but we see that in the stack trace that there are newer wheels that match your system, specifically: FWIW, you should be able to simplify the command you are running: |
Issue description
--platform
flag (along with--no-deps
and--target
) frompip
doesn't seem to get picked up correctly bypipenv
via--extra-pip-args
.Expected result
The installation should succeed since
pip install
does with those flags:Actual result
When possible, provide the verbose output (
--verbose
), especially for locking and dependencies resolving issues.Steps to replicate
Running the commands in the above snippet in an empty directory is sufficient to reproduce this issue.
$ pipenv --support
Pipenv version:
'2023.10.24'
Pipenv location:
'/Users/chan.kang/.pyenv/versions/3.8.17/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/pipenv'
Python location:
'/Users/chan.kang/.pyenv/versions/3.8.17/Library/Frameworks/Python.framework/Versions/3.8/bin/python3.8'
OS Name:
'posix'
User pip version:
'23.3.1'
user Python installations found:
PEP 508 Information:
System environment variables:
SHELL
LSCOLORS
PYENV_HOOK_PATH
GITLAB_PYPI_USERNAME
PYENV_SHELL
BOKEH_SIGN_SESSIONS
XPC_FLAGS
NVM_INC
TERM_PROGRAM_VERSION
REACT_APP_RECAPTCHA_SITE_KEY
GITLAB_PYPI_PROJECT_ID
__CFBundleIdentifier
SSH_AUTH_SOCK
TERM_SESSION_ID
HOMEBREW_PREFIX
SF_WAREHOUSE
GITLAB_PYPI_PASSWORD
PYENV_VERSION
PWD
LOGNAME
STAGE
LLVM_CONFIG
SF_USERNAME
MANPATH
RDS_PASSWORD
LaunchInstanceID
LDFLAGS
HOME
RDS_DB_NAME
LANG
SECURITYSESSIONID
UNLEASH_INSTANCE_ID
SF_ROLE
TMPDIR
CPPFLAGS
CLICOLOR
LOCAL_GRAPHQL_DEV
SF_DATABASE
PYENV_DIR
UNLEASH_URL
INFOPATH
RDS_PORT
NVM_DIR
RDS_HOSTNAME
TERM
SF_ACCOUNT
GITLAB_READ_PACKAGE_REGISTRY_TOKEN
USER
HOMEBREW_CELLAR
RDS_USERNAME
SHLVL
NVM_CD_FLAGS
HOMEBREW_REPOSITORY
SF_PASSWORD
XPC_SERVICE_NAME
PYENV_ROOT
SF_SCHEMA
PATH
BOKEH_SECRET_KEY
NVM_BIN
RECAPTCHA_SECRET_KEY
BOKEH_PY_LOG_LEVEL
OLDPWD
TERM_PROGRAM
__CF_USER_TEXT_ENCODING
PIP_DISABLE_PIP_VERSION_CHECK
PYTHONDONTWRITEBYTECODE
PYTHONFINDER_IGNORE_UNSUPPORTED
Pipenv–specific environment variables:
Debug–specific environment variables:
PATH
:/Users/chan.kang/.pyenv/versions/3.8.17/bin:/Users/chan.kang/.pyenv/versions/3.8.17/bin:/opt/homebrew/Cellar/pyenv/2.3.23/libexec:/opt/homebrew/Cellar/pyenv/2.3.23/plugins/python-build/bin:/Users/chan.kang/.nvm/versions/node/v18.16.1/bin:/Users/chan.kang/.pyenv/shims:/opt/homebrew/opt/postgresql@15/bin:/opt/homebrew/opt/llvm/bin:/opt/homebrew/opt/findutils/libexec/gnubin:/opt/homebrew/opt/libpq/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/Users/chan.kang/.cargo/bin:/Users/chan.kang/.gem/ruby/X.X.0/bin:/usr/local/opt/openjdk/bin:/Users/chan.kang/.local/bin:/opt/homebrew/opt/findutils/libexec/gnubin:/usr/local/bin:/usr/local/opt/grep/libexec/gnubin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin
SHELL
:/opt/homebrew/Cellar/bash/5.2.15/bin/bash
LANG
:en_US.UTF-8
PWD
:/Users/chan.kang/test/tensorflow2
Contents of
Pipfile
('/Users/chan.kang/test/tensorflow2/Pipfile'):The text was updated successfully, but these errors were encountered: