diff --git a/bin/steps/pip-install b/bin/steps/pip-install index 349c895805144724e6bb61a8158a11b6dd21f47a..017f95138b484fe3ba795d6d647a6e5c107af977 100755 --- a/bin/steps/pip-install +++ b/bin/steps/pip-install @@ -1,20 +1,23 @@ -# Install dependencies with Pip. -puts-step "Installing requirements with pip" +if [ ! "$SKIP_PIP_INSTALL" ]; then -set +e -/app/.heroku/python/bin/pip install -r $BUILD_DIR/requirements.txt --exists-action=w --src=/app/.heroku/src --disable-pip-version-check --no-cache-dir 2>&1 | tee $WARNINGS_LOG | cleanup | indent -PIP_STATUS="${PIPESTATUS[0]}" -set -e + # Install dependencies with Pip. + puts-step "Installing requirements with pip" -show-warnings + set +e + /app/.heroku/python/bin/pip install -r $BUILD_DIR/requirements.txt --exists-action=w --src=/app/.heroku/src --disable-pip-version-check --no-cache-dir 2>&1 | tee $WARNINGS_LOG | cleanup | indent + PIP_STATUS="${PIPESTATUS[0]}" + set -e -if [[ ! $PIP_STATUS -eq 0 ]]; then - exit 1 -fi + show-warnings + if [[ ! $PIP_STATUS -eq 0 ]]; then + exit 1 + fi -# Smart Requirements handling -cp requirements.txt .heroku/python/requirements-declared.txt -/app/.heroku/python/bin/pip freeze --disable-pip-version-check > .heroku/python/requirements-installed.txt -echo + # Smart Requirements handling + cp requirements.txt .heroku/python/requirements-declared.txt + /app/.heroku/python/bin/pip freeze --disable-pip-version-check > .heroku/python/requirements-installed.txt + + echo +fi \ No newline at end of file diff --git a/bin/steps/pipenv b/bin/steps/pipenv index 7b8aff9474f980023a0a94157db6cbec9e57c6cd..cdb9d18c4bd3381f58295e38d72203691913aab8 100644 --- a/bin/steps/pipenv +++ b/bin/steps/pipenv @@ -1,10 +1,19 @@ # Pipenv support (Generate requriements.txt with pipenv). if [[ -f Pipfile ]]; then if [[ ! -f requirements.txt ]]; then - puts-step "Generating 'requirements.txt' with pipenv" + puts-step "Installing requirements with latest pipenv..." + # Install pipenv. /app/.heroku/python/bin/pip install pipenv --upgrade &> /dev/null - /app/.heroku/python/bin/pipenv lock --requirements --no-hashes > $BUILD_DIR/requirements.txt 2> /dev/null + # Install the dependencies. + /app/.heroku/python/bin/pipenv install --system 2>&1 | indent + + # Skip pip install, later. + export SKIP_PIP_INSTALL=1 + + # Pip freeze, for compatibility. + /app/.heroku/python/bin/pip freeze > requirements.txt + fi fi \ No newline at end of file diff --git a/builds/runtimes/pypy3-5.7.1 b/builds/runtimes/pypy3-5.7.1 old mode 100644 new mode 100755