-
-
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
Pipenv does not recursively lock dependencies of packages excluded by markers #2429
Comments
Right, we specifically can't ignore top level markers during resolution -- we used to ignore them, but it causes serious issues for things that legitimately can't be installed in the specified environment. For instance, if I say That example is not contrived, that's a real example, we had a lot of bug reports on just that one specific one. Another example is if you put Essentially, if you want something to be resolved into your lockfile, it needs to evaluate as installable in the given environment. This is the nature of python packaging -- if we are told we can't install something we won't attempt to, because if we attempt to run a |
So, what is the solution to have pipenv happy with |
@gsemet thanks for that incredibly helpful feedback. See #2584 #2359 and #2384. Also, even if markers worked as you describe, just because they don’t accomplish a particular thing for you doesn’t mean they are useless and should be removed. Check your attitude before posting on the tracker. You are making a lot of assumptions. |
Hello. I am sorry to have appeared rude. That wasn't my intention. I see my markers being ignored on recent versions while they weren't before and interpret that as a regression. But looking as these closed tickets I though the behavior of pipenv was as expected, while I hope it is not. Markers are really important in Pipfile. They may be weird to see in the lock file, since the lock is the ultimate source of truth in a particular environment. The problem is maybe it is hard to understand for us, users, the delay beween when a ticket is closed and when it is released. Maybe a label "released" ? Or the "milestone" feature of Github? My use case:
|
we know. Thats why I linked you to the bug reports and the fixes. I don't understand how this is possibly interpreted as me telling you this behavior is expected. I don't really need more explanation of what you're doing, this is not complicated. There were some bugs. They have issues, fixes, and dates on them, and yes, even milestones often. Sometimes, we work on code and make changes before releasing it. This is after all github, a place for development of code. We use it to collaborate on this project. If you are not sure if your issue is fixed, install from master and check. |
Can I add piping install mysqlclient after a piping lock? |
With a Pipfile that contains packages restricted by environment markers, running
pipenv lock
from an excluded environment will not recursively lock the excluded packages' dependencies.$ python -m pipenv.help output
Pipenv version:
'2018.6.25'
Pipenv location:
'C:\\Python36\\lib\\site-packages\\pipenv'
Python location:
'C:\\Python36\\python.exe'
Other Python installations in
PATH
:2.7
:C:\Python27\python2.7.exe
2.7
:C:\Python27\python2.7.exe
2.7
:C:\cygwin64\bin\python2.7.exe
3.6
:C:\Python36\python.exe
3.6.5
:C:\Python36\python.exe
2.7.12
:C:\Python27\python.exe
None
:C:\cygwin64\bin\python
2.7.12
:C:\Python27\python2.exe
None
:C:\cygwin64\bin\python2
3.6.5
:C:\Windows\py.exe
PEP 508 Information:
System environment variables:
ALLUSERSPROFILE
ANDROID_SDK_HOME
ANSICON
ANSICON_DEF
ANT_HOME
APPDATA
CHOCOLATEYINSTALL
CHOCOLATEYLASTPATHUPDATE
CLINK_DIR
COMMONPROGRAMFILES
COMMONPROGRAMFILES(X86)
COMMONPROGRAMW6432
COMPUTERNAME
COMSPEC
CONEMUANSI
CONEMUANSILOG
CONEMUARGS
CONEMUARGS2
CONEMUBACKHWND
CONEMUBASEDIR
CONEMUBUILD
CONEMUCONFIG
CONEMUDIR
CONEMUDRAWHWND
CONEMUDRIVE
CONEMUHOOKS
CONEMUHWND
CONEMUPALETTE
CONEMUPID
CONEMUSERVERPID
CONEMUTASK
CONEMUWORKDIR
CONEMUWORKDRIVE
CONNECTIONSTRING
DOKANLIBRARY1
DRIVERDATA
FARHOME
FARLANG
FARLOCALPROFILE
FARPROFILE
FPS_BROWSER_APP_PROFILE_STRING
FPS_BROWSER_USER_PROFILE_STRING
FSHARPINSTALLDIR
GOOGLE_APPLICATION_CREDENTIALS
GOPATH
GOROOT
HOMEDRIVE
HOMEPATH
INTEL_DEV_REDIST
LOCALAPPDATA
LOGONSERVER
MIC_LD_LIBRARY_PATH
MYSQLCONNECTOR_ASSEMBLIESPATH
NDI_RUNTIME_DIR_V2
NDI_RUNTIME_DIR_V3
NUMBER_OF_PROCESSORS
ONEDRIVE
OS
PATH
PATHEXT
PIPENV_DEFAULT_PYTHON_VERSION
PIPENV_SHELL_FANCY
PIPENV_VENV_IN_PROJECT
PROCESSOR_ARCHITECTURE
PROCESSOR_IDENTIFIER
PROCESSOR_LEVEL
PROCESSOR_REVISION
PROGRAMDATA
PROGRAMFILES
PROGRAMFILES(X86)
PROGRAMW6432
PROMPT
PSMODULEPATH
PT7HOME
PUBLIC
RUBYOPT
SESSIONNAME
SYSTEMDRIVE
SYSTEMROOT
TEMP
TMP
TVT
USERDOMAIN
USERDOMAIN_ROAMINGPROFILE
USERNAME
USERPROFILE
VBOX_MSI_INSTALL_PATH
VS140COMNTOOLS
WINDIR
PYTHONDONTWRITEBYTECODE
PIP_PYTHON_PATH
Pipenv–specific environment variables:
PIPENV_DEFAULT_PYTHON_VERSION
:3.6
PIPENV_SHELL_FANCY
:true
PIPENV_VENV_IN_PROJECT
:true
Debug–specific environment variables:
PATH
:C:\Program Files\Far Manager\ConEmu\Scripts;C:\Program Files\Far Manager;C:\Program Files\Far Manager\ConEmu;C:\Program Files (x86)\Graphviz2.38\bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files\Docker\Docker\Resources\bin;C:\Program Files (x86)\Common Files\Intel\Shared Libraries\redist\intel64\compiler;C:\ProgramData\Oracle\Java\javapath;C:\Python36\Scripts\;C:\Python36\;C:\Python27\Scripts;C:\Python27;C:\bin\imagemagick;C:\Program Files\MongoDB\Server\3.4\bin;C:\cygwin64\bin;C:\Program Files (x86)\PuTTY\;C:\bin;C:\Android\sdk\platform-tools;C:\Android\sdk\tools;C:\Users\axnsan\Application Data\npm;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\ProgramData\chocolatey\bin;C:\Program Files\OpenVPN\bin;C:\Program Files\dotnet\;C:\Program Files (x86)\IDA 6.8;C:\Program Files\Calibre2\;C:\Windows\System32;C:\Go\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\nodejs\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files\Git\cmd;C:\WINDOWS\System32\OpenSSH\;C:\texlive\2018\bin\win32;C:\Ruby24-x64\bin;C:\ProgramData\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Program Files\OpenVPN\bin;C:\Program Files (x86)\PuTTY\;C:\Program Files\Git\cmd;C:\Python27\Scripts;C:\Python27;C:\bin;C:\Android\sdk\platform-tools;C:\Android\sdk\tools;C:\Program Files\nodejs\;C:\Users\axnsan\Application Data\npm;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Users\axnsan\AppData\Local\Microsoft\WindowsApps;C:\Program Files (x86)\Diffuse;C:\Users\axnsan\AppData\Roaming\npm;C:\Users\axnsan\AppData\Local\GitHubDesktop\bin;C:\Users\axnsan\AppData\Local\Microsoft\WindowsApps;C:\Program Files (x86)\EaseUS\Todo Backup\bin\x64\
Contents of
Pipfile
('C:\Projects\pipenv-excluded-lock\Pipfile'):Contents of
Pipfile.lock
('C:\Projects\pipenv-excluded-lock\Pipfile.lock'):Expected result
Dependencies of packages are locked so that they properly install on the targeted environment. It works properly when you remove the markers or lock under a matching environment.
Actual result
Only the top-level package is locked.
Steps to replicate
Pipfile
:pipenv lock
pipenv install --ignore-pipfile
on linux using the newPipenv.lock
filedjango-auth-ldap
was installed without its dependenciesThe text was updated successfully, but these errors were encountered: