-
-
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 install fails on proprietary package not available on pypi #1882
Comments
Hey @wooyek sorry for the delay, based on the output it looks like your package requires itself as an installation dependency. This is going to cause you problems because it isn't being assigned a name at installation time. One way you can work around this is by using a Another option which might work is to set the name in the pipfile where you currently will see a 7 character hash -- just change that to I'm not totally sure this will fix the problem for you because the real issue is that your package requires itself somehow, and circular dependencies are always going to cause problems. What I really need to see to troubleshoot is if you install everything using |
Another option is to spin up a custom PyPI on localhost during locking. It’s much easier than you’d think. |
@techalchemy thx for the input. Self dependency wasn't intended, thx for pointing it out, I missed it because pip-compile did not complain. I will check other options, but absolute uri path will not work because it probably won't work on other environments wg. heroku where this path would be |
@uranusjr Would it work with production if local PyPi is just on dev environment for the locking phase? |
You’d need to supply Edit: I think you can do |
@uranusjr the main problem with local PyPi is that it is local. Having it externally available makes a project by itself. You have to maintain it, keep it secure, manage authorization for different project and customers. This is a major effort just to overcome Not to mention TTL for old packages that where used in that legacy project that some customer still uses and maybe will need access to that package. Having this customer have copy of package distribution file is so much easier, even from business and security perspective — no need o official agreement that we we will maintain our PyPi for X years, have SLA's and whatnot. I hope this shows my reasons for being reluctant to spin off our own PyPi service. Tox may have had same problem with it obscuring pip installaction internally, but there is an elegant solution to that in the install_commandhttp://tox.readthedocs.io/en/latest/config.html#confval-install_command=ARGV) setting. You could set it to:
And it works great. But it's not even needed most of the time, it you put in the
I understand that having your own PyPi is awesome and enterprise, but there is a very simple solution in place already — local, relative index folders — let's not throw it away. I just think that instead of making peaople use more internal PyPi instances, we'll encourage them to copy/vendorize libraries inside their projects, as its easier to do. I would like for more people that have internal proprietary packages to distribute them as package archives and not as copies of source code. PS. Thx for the tip about |
This discussion is really annoying because I built support for local relative paths starting in #540. Instead of writing essays complaining that we don’t support your use case, fix your setupfile and get back to us about whether you encounter more resolution issues because we support exactly this use case. Not by some magic or forcing you to use private indexes. Local relative paths are supported. You already know this. You read the issues about them. You shouldn’t need anything special.
|
And to be clear we are not copying tox’s model because their use case is not like ours. Also, we already support what you want. |
I would like to install a company proprietary internal package that is shipped with the project. Is only available in a folder relative to the project root and it's absolute path may vary between environments.
This is at least connected to #958 and #914
Expected result
That the package
multiinfo
would be installed and put in the Pipfile in a way that can be used on production environment.Steps to replicate
python setup.py bdist_wheel
Actual result
$ pipenv install --verbose requirements/local/multiinfo-0.1.0-py2.py3-none-any.whl
$ python -m pipenv.help output
Pipenv version:
'11.9.0'
Pipenv location:
'/home/janusz/.local/venvs/pipenv/lib/python3.5/site-packages/pipenv'
Python location:
'/home/janusz/.local/venvs/pipenv/bin/python'
Other Python installations in
PATH
:2.7
:/usr/bin/python2.7
2.7
:/usr/bin/python2.7
3.4
:/home/janusz/.pyenv/shims/python3.4m
3.4
:/home/janusz/.pyenv/shims/python3.4
3.4
:/home/janusz/.pyenv/shims/python3.4
3.5
:/home/janusz/.pyenv/shims/python3.5m
3.5
:/home/janusz/.local/venvs/pipenv/bin/python3.5
3.5
:/home/janusz/.pyenv/shims/python3.5
3.5
:/home/janusz/.local/venvs/pipenv/bin/python3.5
3.5
:/home/janusz/.pyenv/shims/python3.5
3.5
:/usr/bin/python3.5
3.6
:/home/janusz/.pyenv/shims/python3.6m
3.6
:/home/janusz/.pyenv/shims/python3.6
3.6
:/home/janusz/.pyenv/shims/python3.6
3.5.2
:/home/janusz/.local/venvs/pipenv/bin/python
3.5.2
:/home/janusz/.pyenv/shims/python
3.5.2
:/home/janusz/.local/venvs/pipenv/bin/python
3.5.2
:/home/janusz/.pyenv/shims/python
2.7.12
:/usr/bin/python
2.7.12
:/usr/bin/python2
3.5.2
:/home/janusz/.local/venvs/pipenv/bin/python3
3.5.2
:/home/janusz/.pyenv/shims/python3
3.5.2
:/home/janusz/.local/venvs/pipenv/bin/python3
3.5.2
:/home/janusz/.pyenv/shims/python3
3.5.2
:/usr/bin/python3
PEP 508 Information:
System environment variables:
PAM_KWALLET5_LOGIN
KDE_FULL_SESSION
XDG_SESSION_COOKIE
XDG_SESSION_CLASS
KDE_MULTIHEAD
COLORFGBG
PYTHONDONTWRITEBYTECODE
SHLVL
PWD
XDG_SESSION_PATH
QT_ACCESSIBILITY
PATH
LANGUAGE
KDE_SESSION_UID
PULSE_PROP_OVERRIDE_application.icon_name
TERM
GTK_RC_FILES
MANDATORY_PATH
XDG_SESSION_ID
LOGNAME
KONSOLE_DBUS_WINDOW
KDE_SESSION_VERSION
OMF_PATH
XDG_VTNR
XDG_DATA_DIRS
XCURSOR_THEME
XDG_SESSION_DESKTOP
VIRTUAL_ENV
LANG
PROFILEHOME
XDG_SESSION_TYPE
NVM_BIN
DEFAULTS_PATH
HOME
PIPENV_SHELL_FANCY
PULSE_PROP_OVERRIDE_application.version
QT_LINUX_ACCESSIBILITY_ALWAYS_ON
PYTHONUNBUFFERED
DBUS_SESSION_BUS_ADDRESS
PAM_KWALLET_LOGIN
KONSOLE_DBUS_SERVICE
NVM_CD_FLAGS
SHELL_SESSION_ID
GS_LIB
PYENV_ROOT
QT_AUTO_SCREEN_SCALE_FACTOR
GTK_MODULES
USER
XDG_CONFIG_DIRS
XAUTHORITY
XDG_SEAT
KONSOLE_PROFILE_NAME
PYENV_SHELL
GTK2_RC_FILES
WORKON_HOME
PYENV_HOOK_PATH
DISPLAY
PIP_PYTHON_PATH
SSH_AUTH_SOCK
PYENV_DIR
KONSOLE_DBUS_SESSION
NVM_DIR
PYENV_VERSION
SSH_AGENT_PID
XDG_RUNTIME_DIR
DESKTOP_SESSION
SESSION_MANAGER
SHELL
PULSE_PROP_OVERRIDE_application.name
XDG_CURRENT_DESKTOP
WINDOWID
XDG_SEAT_PATH
OMF_CONFIG
Pipenv–specific environment variables:
PIPENV_SHELL_FANCY
:True
Debug–specific environment variables:
PATH
:/home/janusz/.local/venvs/pipenv/bin:/home/janusz/.pyenv/libexec:/home/janusz/.pyenv/plugins/python-build/bin:/home/janusz/.pyenv/plugins/pyenv-virtualenv/bin:/home/janusz/.pyenv/plugins/pyenv-update/bin:/home/janusz/.pyenv/plugins/pyenv-installer/bin:/home/janusz/.pyenv/plugins/pyenv-doctor/bin:/home/janusz/.pyenv/shims:/home/janusz/.local/bin:/home/janusz/.pyenv/bin:/home/janusz/.local/venvs/pipenv/bin:/home/janusz/.pyenv/shims:/home/janusz/.local/bin:/home/janusz/.pyenv/bin:/home/janusz/.nvm/versions/node/v9.8.0/bin:/home/janusz/bin:/home/janusz/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
SHELL
:/usr/bin/fish
LANG
:pl_PL.UTF-8
PWD
:/home/janusz
VIRTUAL_ENV
:/home/janusz/.local/venvs/pipenv
The text was updated successfully, but these errors were encountered: