pipenv lock -r > ... creates corrupted requirements file
I'm trying to re-build an image from the following Dockerfile:
FROM python:3.6-alpine WORKDIR /opt/app RUN pip install pipenv COPY Pipfile . RUN pipenv lock -r > requirements.txt; pip install -U -r requirements.txt
and getting error on the last step.
pip install packages from the requirements.txt successfully.
Steps to replicate
$ pipenv --support
Python installations found:
PEP 508 Information:
System environment variables:
Pipenv–specific environment variables:
Debug–specific environment variables:
The text was updated successfully, but these errors were encountered:
We did a quick check and this issue looks very darn similar to
This could be a coincidence, but if any of these issues solves your problem then I did a good job
If not, the maintainers will get to this issue shortly.
Tried the same with the previous version (2018.10.13) — works as expected.
Look at first two lines. However, I'm not sure why in the error message I see
- added a new metadata section to more closely emulate Kubernetes manifests - renamed kv_backend to kv_engine - enabled static analysis and security scans in CI - bumped the version to 0.2.0 - pinned pipenv in Dockerfile to avoid regression in new release, see: pypa/pipenv#3239
When you run
Some context: I use the following pattern for bundling Python dependencies as part of an archive builder script for AWS Lambda:
As a workaround, I was able to restore the old behavior with
Got it! sarugaku/vistir#41
Successfully installed certifi-2018.10.15 pipenv-2018.11.15.dev0 virtualenv-16.1.0 virtualenv-clone-0.4.0 Removing intermediate container 032e11add394 ---> c8b1be7e75a5 Step 6/6 : RUN pipenv lock -r > requirements.txt; pip install -U -r requirements.txt ---> Running in 42668600ea5d Creating a virtualenv for this project… Pipfile: /opt/app/Pipfile Running... Using /usr/local/bin/python (3.6.7) to create virtualenv… Running... virtual environment... ⠴ Creating virtual environment...Already using interpreter /usr/local/bin/python Using base prefix '/usr/local' New python executable in /root/.local/share/virtualenvs/app-ueEJiAOq/bin/python Installing setuptools, pip, wheel... done. Removing intermediate container 42668600ea5d ---> 312bc682aa72 Successfully built 312bc682aa72 Successfully tagged pipenv-test:latest