mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 22:50:18 +00:00
Merge branch 'main' into master
This commit is contained in:
@@ -1,31 +0,0 @@
|
||||
steps:
|
||||
- task: UsePythonVersion@0
|
||||
inputs:
|
||||
versionSpec: $(python.version)
|
||||
architecture: '$(python.architecture)'
|
||||
addToPath: true
|
||||
displayName: Use Python $(python.version)
|
||||
|
||||
- template: install-dependencies.yml
|
||||
|
||||
- script: |
|
||||
echo '##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]'$(python.version)
|
||||
env:
|
||||
PYTHON_VERSION: $(python.version)
|
||||
|
||||
- template: create-virtualenv.yml
|
||||
parameters:
|
||||
python_version: $(python.version)
|
||||
|
||||
- script: |
|
||||
python -m pip install --upgrade wheel pip setuptools twine readme_renderer[md]
|
||||
python setup.py sdist bdist_wheel
|
||||
twine check dist/*
|
||||
displayName: Build and check package
|
||||
env:
|
||||
PY_EXE: $(PY_EXE)
|
||||
GIT_SSL_CAINFO: $(GIT_SSL_CAINFO)
|
||||
LANG: $(LANG)
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: $(PIPENV_DEFAULT_PYTHON_VERSION)
|
||||
PYTHONWARNINGS: ignore:DEPRECATION
|
||||
PIPENV_NOSPIN: '1'
|
||||
@@ -1,44 +0,0 @@
|
||||
parameters:
|
||||
python_version: ''
|
||||
|
||||
steps:
|
||||
|
||||
- script: |
|
||||
echo "##vso[task.setvariable variable=LANG]C.UTF-8"
|
||||
echo "##vso[task.setvariable variable=PIP_PROCESS_DEPENDENCY_LINKS]1"
|
||||
displayName: Set Environment Variables
|
||||
|
||||
- ${{ if eq(parameters.vmImage, 'windows-2019') }}:
|
||||
- powershell: |
|
||||
pip install certifi
|
||||
$env:PYTHON_PATH=$(python -c "import sys; print(sys.executable)")
|
||||
$env:CERTIFI_CONTENT=$(python -m certifi)
|
||||
echo "##vso[task.setvariable variable=GIT_SSL_CAINFO]$env:CERTIFI_CONTENT"
|
||||
echo "##vso[task.setvariable variable=PY_EXE]$env:PYTHON_PATH"
|
||||
displayName: Set Python Path
|
||||
env:
|
||||
PYTHONWARNINGS: 'ignore:DEPRECATION'
|
||||
- ${{ if ne(parameters.vmImage, 'windows-2019') }}:
|
||||
- bash: |
|
||||
pip install certifi
|
||||
PYTHON_PATH=$(python -c 'import sys; print(sys.executable)')
|
||||
CERTIFI_CONTENT=$(python -m certifi)
|
||||
echo "##vso[task.setvariable variable=GIT_SSL_CAINFO]$CERTIFI_CONTENT"
|
||||
echo "##vso[task.setvariable variable=PY_EXE]$PYTHON_PATH"
|
||||
displayName: Set Python Path
|
||||
env:
|
||||
PYTHONWARNINGS: 'ignore:DEPRECATION'
|
||||
|
||||
- script: |
|
||||
echo "Python path: $(PY_EXE)"
|
||||
echo "GIT_SSL_CAINFO: $(GIT_SSL_CAINFO)"
|
||||
echo "PIPENV PYTHON VERSION: $(python.version)"
|
||||
echo "python_version: ${{ parameters.python_version }}"
|
||||
git submodule sync
|
||||
git submodule update --init --recursive
|
||||
$(PY_EXE) -m pipenv install --deploy --dev --python="$(PY_EXE)"
|
||||
env:
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: ${{ parameters.python_version }}
|
||||
PYTHONWARNINGS: 'ignore:DEPRECATION'
|
||||
PIPENV_NOSPIN: '1'
|
||||
displayName: Make Virtualenv
|
||||
@@ -1,5 +0,0 @@
|
||||
steps:
|
||||
- script: 'python -m pip install --upgrade pip setuptools wheel -e .[dev,tests] --upgrade'
|
||||
displayName: Upgrade Pip & Install Pipenv
|
||||
env:
|
||||
PYTHONWARNINGS: 'ignore:DEPRECATION'
|
||||
@@ -1,34 +0,0 @@
|
||||
steps:
|
||||
- script: |
|
||||
# When you paste this, please make sure the indentation is preserved
|
||||
# Fail out if any setups fail
|
||||
set -e
|
||||
|
||||
# Delete old Pythons
|
||||
rm -rf $AGENT_TOOLSDIRECTORY/Python/2.7.16
|
||||
rm -rf $AGENT_TOOLSDIRECTORY/Python/3.5.7
|
||||
rm -rf $AGENT_TOOLSDIRECTORY/Python/3.7.3
|
||||
[ -e $AGENT_TOOLSDIRECTORY/Python/3.7.2 ] && [ -e $AGENT_TOOLSDIRECTORY/Python/3.5.5 ] && [ -e $AGENT_TOOLSDIRECTORY/Python/2.7.15 ] && exit 0
|
||||
# Download new Pythons
|
||||
azcopy --recursive \
|
||||
--source https://vstsagenttools.blob.core.windows.net/tools/hostedtoolcache/linux/Python/2.7.15 \
|
||||
--destination $AGENT_TOOLSDIRECTORY/Python/2.7.15
|
||||
|
||||
azcopy --recursive \
|
||||
--source https://vstsagenttools.blob.core.windows.net/tools/hostedtoolcache/linux/Python/3.5.5 \
|
||||
--destination $AGENT_TOOLSDIRECTORY/Python/3.5.5
|
||||
|
||||
azcopy --recursive \
|
||||
--source https://vstsagenttools.blob.core.windows.net/tools/hostedtoolcache/linux/Python/3.7.2 \
|
||||
--destination $AGENT_TOOLSDIRECTORY/Python/3.7.2
|
||||
|
||||
# Install new Pythons
|
||||
original_directory=$PWD
|
||||
setups=$(find $AGENT_TOOLSDIRECTORY/Python -name setup.sh)
|
||||
for setup in $setups; do
|
||||
chmod +x $setup;
|
||||
cd $(dirname $setup);
|
||||
./$(basename $setup);
|
||||
cd $original_directory;
|
||||
done;
|
||||
displayName: 'Workaround: roll back Python versions'
|
||||
@@ -1,14 +0,0 @@
|
||||
parameters:
|
||||
python_version: ''
|
||||
|
||||
steps:
|
||||
- script: |
|
||||
# Fix Git SSL errors
|
||||
echo "Using pipenv python version: $(PIPENV_DEFAULT_PYTHON_VERSION)"
|
||||
git submodule sync && git submodule update --init --recursive
|
||||
pipenv run pytest --junitxml=test-results.xml
|
||||
displayName: Run integration tests
|
||||
env:
|
||||
PYTHONWARNINGS: ignore:DEPRECATION
|
||||
PIPENV_NOSPIN: '1'
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: ${{ parameters.python_version }}
|
||||
@@ -1,21 +0,0 @@
|
||||
parameters:
|
||||
python_version: ''
|
||||
|
||||
steps:
|
||||
- powershell: |
|
||||
subst T: "$env:TEMP"
|
||||
Write-Host "##vso[task.setvariable variable=TEMP]T:\"
|
||||
Write-Host "##vso[task.setvariable variable=TMP]T:\"
|
||||
Write-Host "##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]$env:PYTHON_VERSION"
|
||||
Write-Host "##vso[task.setvariable variable=PIPENV_NOSPIN]1"
|
||||
displayName: Fix Temp Variable
|
||||
env:
|
||||
PYTHON_VERSION: ${{ parameters.python_version }}
|
||||
|
||||
- script: |
|
||||
git submodule sync && git submodule update --init --recursive
|
||||
pipenv run pytest -ra --ignore=pipenv\patched --ignore=pipenv\vendor --junitxml=test-results.xml tests
|
||||
displayName: Run integration tests
|
||||
env:
|
||||
PYTHONWARNINGS: 'ignore:DEPRECATION'
|
||||
PIPENV_NOSPIN: '1'
|
||||
@@ -1,34 +0,0 @@
|
||||
steps:
|
||||
- task: UsePythonVersion@0
|
||||
inputs:
|
||||
versionSpec: $(python.version)
|
||||
architecture: '$(python.architecture)'
|
||||
addToPath: true
|
||||
displayName: Use Python $(python.version)
|
||||
|
||||
- template: install-dependencies.yml
|
||||
|
||||
- script: |
|
||||
echo '##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]'$(python.version)
|
||||
env:
|
||||
PYTHON_VERSION: $(python.version)
|
||||
|
||||
- template: create-virtualenv.yml
|
||||
parameters:
|
||||
python_version: $(python.version)
|
||||
|
||||
- ${{ if eq(parameters.vmImage, 'windows-2019') }}:
|
||||
- template: run-tests-windows.yml
|
||||
parameters:
|
||||
python_version: $(python.version)
|
||||
- ${{ if ne(parameters.vmImage, 'windows-2019') }}:
|
||||
- template: run-tests-linux.yml
|
||||
parameters:
|
||||
python_version: $(python.version)
|
||||
|
||||
- task: PublishTestResults@2
|
||||
displayName: Publish Test Results
|
||||
inputs:
|
||||
testResultsFiles: '**/test-results.xml'
|
||||
testRunTitle: 'Python $(python.version)'
|
||||
condition: succeededOrFailed()
|
||||
@@ -1,33 +0,0 @@
|
||||
parameters:
|
||||
python_version: ''
|
||||
|
||||
steps:
|
||||
- task: UsePythonVersion@0
|
||||
inputs:
|
||||
versionSpec: $(python.version)
|
||||
architecture: '$(python.architecture)'
|
||||
addToPath: true
|
||||
displayName: Use Python $(python.version)
|
||||
|
||||
- template: install-dependencies.yml
|
||||
|
||||
- script: |
|
||||
echo '##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]'$(python.version)
|
||||
env:
|
||||
PYTHON_VERSION: $(python.version)
|
||||
|
||||
- template: create-virtualenv.yml
|
||||
parameters:
|
||||
python_version: $(python.version)
|
||||
|
||||
- script: |
|
||||
python -m pip install --upgrade invoke requests parver bs4 vistir towncrier pip setuptools wheel --upgrade-strategy=eager
|
||||
python -m invoke vendoring.update
|
||||
displayName: Run Vendor Scripts
|
||||
env:
|
||||
PY_EXE: $(PY_EXE)
|
||||
GIT_SSL_CAINFO: $(GIT_SSL_CAINFO)
|
||||
LANG: $(LANG)
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: '${{ parameters.python_version }}'
|
||||
PYTHONWARNINGS: ignore:DEPRECATION
|
||||
PIPENV_NOSPIN: '1'
|
||||
@@ -1,5 +0,0 @@
|
||||
steps:
|
||||
- label: ":python:"
|
||||
commands:
|
||||
# - make
|
||||
- ./run-tests.sh
|
||||
@@ -1,10 +0,0 @@
|
||||
{
|
||||
"name": "Pipenv Test Suite",
|
||||
"steps": [
|
||||
{
|
||||
"type": "script",
|
||||
"name": ":pipeline:",
|
||||
"command": "buildkite-agent pipeline upload"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
version = 1
|
||||
|
||||
test_patterns = ["tests/**"]
|
||||
|
||||
exclude_patterns = [
|
||||
"examples/**",
|
||||
"pipenv/vendor/**",
|
||||
"pipenv/patched/**"
|
||||
]
|
||||
|
||||
[[analyzers]]
|
||||
name = "python"
|
||||
enabled = true
|
||||
|
||||
[analyzers.meta]
|
||||
runtime_version = "3.x.x"
|
||||
@@ -1,11 +0,0 @@
|
||||
./examples
|
||||
./tests
|
||||
./docs
|
||||
./news
|
||||
./pipenv
|
||||
./.git
|
||||
./.buildkite
|
||||
./peeps
|
||||
./.github
|
||||
./tasks
|
||||
./.azure-pipelines
|
||||
@@ -1,42 +0,0 @@
|
||||
Be sure to check the existing issues (both open and closed!), and make sure you are running the latest version of Pipenv.
|
||||
|
||||
If you're requesting a new feature, please use the PEEP process:
|
||||
|
||||
https://github.com/pypa/pipenv/blob/master/peeps/PEEP-000.md
|
||||
|
||||
Check the [diagnose documentation](https://docs.pipenv.org/diagnose/) for common issues before posting! We may close your issue if it is very similar to one of them. Please be considerate, or be on your way.
|
||||
|
||||
Make sure to mention your debugging experience if the documented solution failed.
|
||||
|
||||
|
||||
### Issue description
|
||||
|
||||
Describe the issue briefly here.
|
||||
|
||||
### Expected result
|
||||
|
||||
Describe what you expected.
|
||||
|
||||
### Actual result
|
||||
|
||||
When possible, provide the verbose output (`--verbose`), especially for locking and dependencies resolving issues.
|
||||
|
||||
### Steps to replicate
|
||||
|
||||
Provide the steps to replicate (which usually at least includes the commands and the Pipfile).
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
Please run `$ pipenv --support`, and paste the results here. Don't put backticks (`` ` ``) around it! The output already contains Markdown formatting.
|
||||
|
||||
If you're on macOS, run the following:
|
||||
|
||||
$ pipenv --support | pbcopy
|
||||
|
||||
If you're on Windows, run the following:
|
||||
|
||||
> pipenv --support | clip
|
||||
|
||||
If you're on Linux, run the following:
|
||||
|
||||
$ pipenv --support | xclip
|
||||
@@ -5,7 +5,7 @@ about: Suggest an idea for this project
|
||||
|
||||
Be sure to check the existing issues (both open and closed!), and make sure you are running the latest version of Pipenv.
|
||||
|
||||
Check the [diagnose documentation](https://docs.pipenv.org/diagnose/) for common issues and the [PEEP list](https://github.com/pypa/pipenv/blob/master/peeps/) before posting! We may close your issue if it is very similar to one of them. Please be considerate and follow the PEEP process, or be on your way.
|
||||
Check the [diagnose documentation](https://pipenv.pypa.io/en/latest/diagnose/) for common issues and the [PEEP list](https://github.com/pypa/pipenv/blob/master/peeps/) before posting! We may close your issue if it is very similar to one of them. Please be considerate and follow the PEEP process, or be on your way.
|
||||
|
||||
Make sure to mention your debugging experience if the documented solution failed.
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ What is the thing you want to fix? Is it associated with an issue on GitHub? Ple
|
||||
|
||||
Always consider opening an issue first to describe your problem, so we can discuss what is the best way to amend it. Note that if you do not describe the goal of this change or link to a related issue, the maintainers may close the PR without further review.
|
||||
|
||||
If your pull request makes a non-insignificant change to Pipenv, such as the user interface or intended functionality, please file a PEEP.
|
||||
If your pull request makes a non-insignificant change to Pipenv, such as the user interface or intended functionality, please file a PEEP.
|
||||
|
||||
https://github.com/pypa/pipenv/blob/master/peeps/PEEP-000.md
|
||||
|
||||
@@ -22,7 +22,7 @@ How does this pull request fix your problem? Did you consider any alternatives?
|
||||
* [ ] A news fragment in the `news/` directory to describe this fix with the extension `.bugfix`, `.feature`, `.behavior`, `.doc`. `.vendor`. or `.trivial` (this will appear in the release changelog). Use semantic line breaks and name the file after the issue number or the PR #.
|
||||
|
||||
<!--
|
||||
### If this is a patch to the `vendor` directory…
|
||||
### If this is a patch to the `vendor` directory...
|
||||
|
||||
Please try to refrain from submitting patches directly to `vendor` or `patched`, but raise your issue to the upstream project instead, and inform Pipenv to upgrade when the upstream project accepts the fix.
|
||||
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
paths-ignore:
|
||||
- "docs/**"
|
||||
- "news/**"
|
||||
- "examples/**"
|
||||
- "peeps/**"
|
||||
- "*.ini"
|
||||
- "*.md"
|
||||
- "**/*.txt"
|
||||
- "*.rst"
|
||||
- ".gitignore"
|
||||
- ".gitmodules"
|
||||
- ".gitattributes"
|
||||
- ".editorconfig"
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- "docs/**"
|
||||
- "news/**"
|
||||
- "examples/**"
|
||||
- "peeps/**"
|
||||
- "*.ini"
|
||||
- "*.md"
|
||||
- "**/*.txt"
|
||||
- "*.rst"
|
||||
- ".gitignore"
|
||||
- ".gitmodules"
|
||||
- ".gitattributes"
|
||||
- ".editorconfig"
|
||||
|
||||
jobs:
|
||||
tests:
|
||||
name: ${{matrix.os}} / ${{ matrix.python-version }}
|
||||
runs-on: ${{ matrix.os }}-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: [3.7, 3.8, 3.9, "3.10"]
|
||||
os: [MacOS, Ubuntu, Windows]
|
||||
include:
|
||||
- python-version: 3.6
|
||||
os: Ubuntu
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v1
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Get python path
|
||||
id: python-path
|
||||
run: |
|
||||
echo ::set-output name=path::$(python -c "import sys; print(sys.executable)")
|
||||
|
||||
- name: Install latest pip, setuptools, wheel
|
||||
run: |
|
||||
python -m pip install --upgrade pip setuptools wheel --upgrade-strategy=eager
|
||||
- name: Install dependencies
|
||||
env:
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
PYTHONWARNINGS: ignore:DEPRECATION
|
||||
PYTHONIOENCODING: "utf-8"
|
||||
GIT_ASK_YESNO: "false"
|
||||
run: |
|
||||
git submodule sync
|
||||
git submodule update --init --recursive
|
||||
python -m pip install -e . --upgrade
|
||||
pipenv install --deploy --dev --python=${{ steps.python-path.outputs.path }}
|
||||
- name: Run tests
|
||||
env:
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
PYTHONWARNINGS: ignore:DEPRECATION
|
||||
PIPENV_NOSPIN: "1"
|
||||
CI: "1"
|
||||
GIT_ASK_YESNO: "false"
|
||||
PYPI_VENDOR_DIR: "./tests/pypi/"
|
||||
PYTHONIOENCODING: "utf-8"
|
||||
GIT_SSH_COMMAND: ssh -o StrictHostKeyChecking=accept-new -o CheckHostIP=no
|
||||
run: |
|
||||
pipenv run pytest -ra -n auto --fulltrace tests
|
||||
|
||||
build:
|
||||
name: Build Package
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.9
|
||||
- run: pip install -U build twine
|
||||
- run: |
|
||||
python -m build
|
||||
twine check dist/*
|
||||
|
||||
vendor:
|
||||
name: Vendoring
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.9
|
||||
- run: |
|
||||
python -m pip install --upgrade wheel invoke parver bs4 vistir towncrier
|
||||
python -m invoke vendoring.update
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
name: Upload Python Package
|
||||
|
||||
on:
|
||||
push:
|
||||
# Sequence of patterns matched against refs/tags
|
||||
tags:
|
||||
- v[0-9]+.[0-9]+.* # add .* to allow dev releases
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
name: pipenv PyPI Upload
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
CI: "1"
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Create Release
|
||||
id: create_release
|
||||
uses: actions/create-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: ${{ github.ref }}
|
||||
release_name: Release ${{ github.ref }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
|
||||
- name: Set up Python 3.9
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.9
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade --upgrade-strategy=eager pip setuptools wheel twine
|
||||
python -m pip install .
|
||||
python -m pipenv install --dev
|
||||
env:
|
||||
PIPENV_DEFAULT_PYTHON_VERSION: "3.9"
|
||||
|
||||
- name: Build wheels
|
||||
run: |
|
||||
python -m pipenv run python setup.py sdist bdist_wheel
|
||||
|
||||
# to upload to test pypi, pass repository_url: https://test.pypi.org/legacy/ and use secrets.TEST_PYPI_TOKEN
|
||||
- name: Publish a Python distribution to PyPI
|
||||
uses: pypa/gh-action-pypi-publish@master
|
||||
with:
|
||||
user: __token__
|
||||
password: ${{ secrets.PYPI_TOKEN }}
|
||||
# repository_url: https://test.pypi.org/legacy/
|
||||
packages_dir: dist/
|
||||
|
||||
# git push https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git HEAD:master
|
||||
# we need to use a deploy key for this to get around branch protection as the default token fails
|
||||
- name: Pre-bump
|
||||
run: |
|
||||
git config --local user.name 'github-actions[bot]'
|
||||
git config --local user.email 'github-actions[bot]@users.noreply.github.com'
|
||||
python -m pipenv run inv release.bump-version --dev --commit
|
||||
|
||||
- name: Push changes
|
||||
uses: ad-m/github-push-action@master
|
||||
with:
|
||||
github_token: ${{ secrets.REPO_TOKEN }}
|
||||
+3
-2
@@ -47,9 +47,9 @@ __pycache__/
|
||||
|
||||
# Distribution / packaging
|
||||
.Python
|
||||
build/
|
||||
/build/
|
||||
develop-eggs/
|
||||
dist/
|
||||
/dist/
|
||||
downloads/
|
||||
eggs/
|
||||
.eggs/
|
||||
@@ -167,3 +167,4 @@ snap/
|
||||
prime/
|
||||
stage/
|
||||
pip-wheel-metadata/
|
||||
.vim/
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
[submodule "tests/test_artifacts/git/six-1.9.0"]
|
||||
path = tests/test_artifacts/git/six-1.9.0
|
||||
url = https://github.com/benjaminp/six.git
|
||||
[submodule "tests/test_artifacts/git/pinax"]
|
||||
path = tests/test_artifacts/git/pinax
|
||||
url = https://github.com/pinax/pinax.git
|
||||
@@ -22,9 +19,6 @@
|
||||
[submodule "tests/test_artifacts/git/flask"]
|
||||
path = tests/test_artifacts/git/flask
|
||||
url = https://github.com/pallets/flask.git
|
||||
[submodule "tests/test_artifacts/git/requests-2.18.4"]
|
||||
path = tests/test_artifacts/git/requests-2.18.4
|
||||
url = https://github.com/psf/requests
|
||||
[submodule "tests/pypi"]
|
||||
path = tests/pypi
|
||||
url = https://github.com/sarugaku/pipenv-test-artifacts.git
|
||||
|
||||
+579
-32
@@ -1,3 +1,550 @@
|
||||
2022.1.8 (2022-01-08)
|
||||
=====================
|
||||
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Remove the extra parentheses around the venv prompt. `#4877 <https://github.com/pypa/pipenv/issues/4877>`_
|
||||
- Fix a bug of installation fails when extra index url is given. `#4881 <https://github.com/pypa/pipenv/issues/4881>`_
|
||||
- Fix regression where lockfiles would only include the hashes for releases for the platform generating the lockfile `#4885 <https://github.com/pypa/pipenv/issues/4885>`_
|
||||
- Fix the index parsing to reject illegal requirements.txt. `#4899 <https://github.com/pypa/pipenv/issues/4899>`_
|
||||
|
||||
|
||||
2021.11.23 (2021-11-23)
|
||||
=======================
|
||||
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Update ``charset-normalizer`` from ``2.0.3`` to ``2.0.7``, this fixes an import error on Python 3.6. `#4865 <https://github.com/pypa/pipenv/issues/4865>`_
|
||||
- Fix a bug of deleting a virtualenv that is not managed by Pipenv. `#4867 <https://github.com/pypa/pipenv/issues/4867>`_
|
||||
- Fix a bug that source is not added to ``Pipfile`` when index url is given with ``pipenv install``. `#4873 <https://github.com/pypa/pipenv/issues/4873>`_
|
||||
|
||||
|
||||
2021.11.15 (2021-11-15)
|
||||
=======================
|
||||
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Return an empty dict when ``PIPENV_DONT_LOAD_ENV`` is set. `#4851 <https://github.com/pypa/pipenv/issues/4851>`_
|
||||
- Don't use ``sys.executable`` when inside an activated venv. `#4852 <https://github.com/pypa/pipenv/issues/4852>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Drop the vendored ``jinja2`` dependency as it is not needed any more. `#4858 <https://github.com/pypa/pipenv/issues/4858>`_
|
||||
- Update ``click`` from ``8.0.1`` to ``8.0.3``, to fix a problem with bash completion. `#4860 <https://github.com/pypa/pipenv/issues/4860>`_
|
||||
- Drop unused vendor ``chardet``. `#4862 <https://github.com/pypa/pipenv/issues/4862>`_
|
||||
|
||||
Improved Documentation
|
||||
----------------------
|
||||
|
||||
- Fix the documentation to reflect the fact that special characters must be percent-encoded in the URL. `#4856 <https://github.com/pypa/pipenv/issues/4856>`_
|
||||
|
||||
|
||||
2021.11.9 (2021-11-09)
|
||||
======================
|
||||
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- Replace ``click-completion`` with ``click``'s own completion implementation. `#4786 <https://github.com/pypa/pipenv/issues/4786>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fix a bug that ``pipenv run`` doesn't set environment variables correctly. `#4831 <https://github.com/pypa/pipenv/issues/4831>`_
|
||||
- Fix a bug that certifi can't be loaded within ``notpip``'s vendor library. This makes several objects of ``pip`` fail to be imported. `#4833 <https://github.com/pypa/pipenv/issues/4833>`_
|
||||
- Fix a bug that ``3.10.0`` can be found be python finder. `#4837 <https://github.com/pypa/pipenv/issues/4837>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update ``pythonfinder`` from ``1.2.8`` to ``1.2.9``. `#4837 <https://github.com/pypa/pipenv/issues/4837>`_
|
||||
|
||||
|
||||
2021.11.5.post0 (2021-11-05)
|
||||
============================
|
||||
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fix a regression that ``pipenv shell`` fails to start a subshell. `#4828 <https://github.com/pypa/pipenv/issues/4828>`_
|
||||
- Fix a regression that ``pip_shims`` object isn't imported correctly. `#4829 <https://github.com/pypa/pipenv/issues/4829>`_
|
||||
|
||||
|
||||
2021.11.5 (2021-11-05)
|
||||
======================
|
||||
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- Avoid sharing states but create project objects on demand. So that most integration test cases are able to switch to a in-process execution method. `#4757 <https://github.com/pypa/pipenv/issues/4757>`_
|
||||
- Shell-quote ``pip`` commands when logging. `#4760 <https://github.com/pypa/pipenv/issues/4760>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Ignore empty .venv in rood dir and create project name base virtual environment `#4790 <https://github.com/pypa/pipenv/issues/4790>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update vendored dependencies
|
||||
- ``attrs`` from ``20.3.0`` to ``21.2.0``
|
||||
- ``cerberus`` from ``1.3.2`` to ``1.3.4``
|
||||
- ``certifi`` from ``2020.11.8`` to ``2021.5.30``
|
||||
- ``chardet`` from ``3.0.4`` to ``4.0.0``
|
||||
- ``click`` from ``7.1.2`` to ``8.0.1``
|
||||
- ``distlib`` from ``0.3.1`` to ``0.3.2``
|
||||
- ``idna`` from ``2.10`` to ``3.2``
|
||||
- ``importlib-metadata`` from ``2.0.0`` to ``4.6.1``
|
||||
- ``importlib-resources`` from ``3.3.0`` to ``5.2.0``
|
||||
- ``jinja2`` from ``2.11.2`` to ``3.0.1``
|
||||
- ``markupsafe`` from ``1.1.1`` to ``2.0.1``
|
||||
- ``more-itertools`` from ``5.0.0`` to ``8.8.0``
|
||||
- ``packaging`` from ``20.8`` to ``21.0``
|
||||
- ``pep517`` from ``0.9.1`` to ``0.11.0``
|
||||
- ``pipdeptree`` from ``1.0.0`` to ``2.0.0``
|
||||
- ``ptyprocess`` from ``0.6.0`` to ``0.7.0``
|
||||
- ``python-dateutil`` from ``2.8.1`` to ``2.8.2``
|
||||
- ``python-dotenv`` from ``0.15.0`` to ``0.19.0``
|
||||
- ``pythonfinder`` from ``1.2.5`` to ``1.2.8``
|
||||
- ``requests`` from ``2.25.0`` to ``2.26.0``
|
||||
- ``shellingham`` from ``1.3.2`` to ``1.4.0``
|
||||
- ``six`` from ``1.15.0`` to ``1.16.0``
|
||||
- ``tomlkit`` from ``0.7.0`` to ``0.7.2``
|
||||
- ``urllib3`` from ``1.26.1`` to ``1.26.6``
|
||||
- ``zipp`` from ``1.2.0`` to ``3.5.0``
|
||||
|
||||
Add new vendored dependencies
|
||||
- ``charset-normalizer 2.0.3``
|
||||
- ``termcolor 1.1.0``
|
||||
- ``tomli 1.1.0``
|
||||
- ``wheel 0.36.2`` `#4747 <https://github.com/pypa/pipenv/issues/4747>`_
|
||||
- Drop the dependencies for Python 2.7 compatibility purpose. `#4751 <https://github.com/pypa/pipenv/issues/4751>`_
|
||||
- Switch the dependency resolver from ``pip-tools`` to `pip`.
|
||||
|
||||
Update vendor libraries:
|
||||
- Update ``requirementslib`` from ``1.5.16`` to ``1.6.1``
|
||||
- Update ``pip-shims`` from ``0.5.6`` to ``0.6.0``
|
||||
- New vendor ``platformdirs 2.4.0`` `#4759 <https://github.com/pypa/pipenv/issues/4759>`_
|
||||
|
||||
Improved Documentation
|
||||
----------------------
|
||||
|
||||
- remove prefixes on install commands for easy copy/pasting `#4792 <https://github.com/pypa/pipenv/issues/4792>`_
|
||||
- Officially drop support for Python 2.7 and Python 3.5. `#4261 <https://github.com/pypa/pipenv/issues/4261>`_
|
||||
|
||||
|
||||
2021.5.29 (2021-05-29)
|
||||
======================
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fix a bug where passing --skip-lock when PIPFILE has no [SOURCE] section throws the error: "tomlkit.exceptions.NonExistentKey: 'Key "source" does not exist.'" `#4141 <https://github.com/pypa/pipenv/issues/4141>`_
|
||||
- Fix bug where environment wouldn't activate in paths containing & and $ symbols `#4538 <https://github.com/pypa/pipenv/issues/4538>`_
|
||||
- Fix a bug that ``importlib-metadata`` from the project's dependencies conflicts with that from ``pipenv``'s. `#4549 <https://github.com/pypa/pipenv/issues/4549>`_
|
||||
- Fix a bug where ``pep508checker.py`` did not expect double-digit Python minor versions (e.g. "3.10"). `#4602 <https://github.com/pypa/pipenv/issues/4602>`_
|
||||
- Fix bug where environment wouldn't activate in paths containing () and [] symbols `#4615 <https://github.com/pypa/pipenv/issues/4615>`_
|
||||
- Fix bug preventing use of pipenv lock --pre `#4642 <https://github.com/pypa/pipenv/issues/4642>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update ``packaging`` from ``20.4`` to ``20.8``. `#4591 <https://github.com/pypa/pipenv/issues/4591>`_
|
||||
|
||||
|
||||
2020.11.15 (2020-11-15)
|
||||
=======================
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- Support expanding environment variables in requirement URLs. `#3516 <https://github.com/pypa/pipenv/issues/3516>`_
|
||||
- Show warning message when a dependency is skipped in locking due to the mismatch of its markers. `#4346 <https://github.com/pypa/pipenv/issues/4346>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fix a bug that executable scripts with leading backslash can't be executed via ``pipenv run``. `#4368 <https://github.com/pypa/pipenv/issues/4368>`_
|
||||
- Fix a bug that VCS dependencies always satisfy even if the ref has changed. `#4387 <https://github.com/pypa/pipenv/issues/4387>`_
|
||||
- Restrict the acceptable hash type to SHA256 only. `#4517 <https://github.com/pypa/pipenv/issues/4517>`_
|
||||
- Fix the output of ``pipenv scripts`` under Windows platform. `#4523 <https://github.com/pypa/pipenv/issues/4523>`_
|
||||
- Fix a bug that the resolver takes wrong section to validate constraints. `#4527 <https://github.com/pypa/pipenv/issues/4527>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update vendored dependencies:
|
||||
- ``colorama`` from ``0.4.3`` to ``0.4.4``
|
||||
- ``python-dotenv`` from ``0.10.3`` to ``0.15.0``
|
||||
- ``first`` from ``2.0.1`` to ``2.0.2``
|
||||
- ``iso8601`` from ``0.1.12`` to ``0.1.13``
|
||||
- ``parse`` from ``1.15.0`` to ``1.18.0``
|
||||
- ``pipdeptree`` from ``0.13.2`` to ``1.0.0``
|
||||
- ``requests`` from ``2.23.0`` to ``2.25.0``
|
||||
- ``idna`` from ``2.9`` to ``2.10``
|
||||
- ``urllib3`` from ``1.25.9`` to ``1.26.1``
|
||||
- ``certifi`` from ``2020.4.5.1`` to ``2020.11.8``
|
||||
- ``requirementslib`` from ``1.5.15`` to ``1.5.16``
|
||||
- ``attrs`` from ``19.3.0`` to ``20.3.0``
|
||||
- ``distlib`` from ``0.3.0`` to ``0.3.1``
|
||||
- ``packaging`` from ``20.3`` to ``20.4``
|
||||
- ``six`` from ``1.14.0`` to ``1.15.0``
|
||||
- ``semver`` from ``2.9.0`` to ``2.13.0``
|
||||
- ``toml`` from ``0.10.1`` to ``0.10.2``
|
||||
- ``cached-property`` from ``1.5.1`` to ``1.5.2``
|
||||
- ``yaspin`` from ``0.14.3`` to ``1.2.0``
|
||||
- ``resolvelib`` from ``0.3.0`` to ``0.5.2``
|
||||
- ``pep517`` from ``0.8.2`` to ``0.9.1``
|
||||
- ``zipp`` from ``0.6.0`` to ``1.2.0``
|
||||
- ``importlib-metadata`` from ``1.6.0`` to ``2.0.0``
|
||||
- ``importlib-resources`` from ``1.5.0`` to ``3.3.0`` `#4533 <https://github.com/pypa/pipenv/issues/4533>`_
|
||||
|
||||
Improved Documentation
|
||||
----------------------
|
||||
|
||||
- Fix suggested pyenv setup to avoid using shimmed interpreter `#4534 <https://github.com/pypa/pipenv/issues/4534>`_
|
||||
|
||||
|
||||
2020.11.4 (2020-11-04)
|
||||
======================
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- Add a new command ``pipenv scripts`` to display shortcuts from Pipfile. `#3686 <https://github.com/pypa/pipenv/issues/3686>`_
|
||||
- Retrieve package file hash from URL to accelerate the locking process. `#3827 <https://github.com/pypa/pipenv/issues/3827>`_
|
||||
- Add the missing ``--system`` option to ``pipenv sync``. `#4441 <https://github.com/pypa/pipenv/issues/4441>`_
|
||||
- Add a new option pair ``--header/--no-header`` to ``pipenv lock`` command,
|
||||
which adds a header to the generated requirements.txt `#4443 <https://github.com/pypa/pipenv/issues/4443>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fix a bug that percent encoded characters will be unquoted incorrectly in the file URL. `#4089 <https://github.com/pypa/pipenv/issues/4089>`_
|
||||
- Fix a bug where setting PIPENV_PYTHON to file path breaks environment name `#4225 <https://github.com/pypa/pipenv/issues/4225>`_
|
||||
- Fix a bug that paths are not normalized before comparison. `#4330 <https://github.com/pypa/pipenv/issues/4330>`_
|
||||
- Handle Python major and minor versions correctly in Pipfile creation. `#4379 <https://github.com/pypa/pipenv/issues/4379>`_
|
||||
- Fix a bug that non-wheel file requirements can be resolved successfully. `#4386 <https://github.com/pypa/pipenv/issues/4386>`_
|
||||
- Fix a bug that ``pexept.exceptions.TIMEOUT`` is not caught correctly because of the wrong import path. `#4424 <https://github.com/pypa/pipenv/issues/4424>`_
|
||||
- Fix a bug that compound TOML table is not parsed correctly. `#4433 <https://github.com/pypa/pipenv/issues/4433>`_
|
||||
- Fix a bug that invalid Python paths from Windows registry break ``pipenv install``. `#4436 <https://github.com/pypa/pipenv/issues/4436>`_
|
||||
- Fix a bug that function calls in ``setup.py`` can't be parsed rightly. `#4446 <https://github.com/pypa/pipenv/issues/4446>`_
|
||||
- Fix a bug that dist-info inside ``venv`` directory will be mistaken as the editable package's metadata. `#4480 <https://github.com/pypa/pipenv/issues/4480>`_
|
||||
- Make the order of hashes in resolution result stable. `#4513 <https://github.com/pypa/pipenv/issues/4513>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update ``tomlkit`` from ``0.5.11`` to ``0.7.0``. `#4433 <https://github.com/pypa/pipenv/issues/4433>`_
|
||||
- Update ``requirementslib`` from ``1.5.13`` to ``1.5.14``. `#4480 <https://github.com/pypa/pipenv/issues/4480>`_
|
||||
|
||||
Improved Documentation
|
||||
----------------------
|
||||
|
||||
- Discourage homebrew installation in installation guides. `#4013 <https://github.com/pypa/pipenv/issues/4013>`_
|
||||
|
||||
|
||||
2020.8.13 (2020-08-13)
|
||||
======================
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fixed behaviour of ``pipenv uninstall --all-dev``.
|
||||
From now on it does not uninstall regular packages. `#3722 <https://github.com/pypa/pipenv/issues/3722>`_
|
||||
- Fix a bug that incorrect Python path will be used when ``--system`` flag is on. `#4315 <https://github.com/pypa/pipenv/issues/4315>`_
|
||||
- Fix falsely flagging a Homebrew installed Python as a virtual environment `#4316 <https://github.com/pypa/pipenv/issues/4316>`_
|
||||
- Fix a bug that ``pipenv uninstall`` throws an exception that does not exist. `#4321 <https://github.com/pypa/pipenv/issues/4321>`_
|
||||
- Fix a bug that Pipenv can't locate the correct file of special directives in ``setup.cfg`` of an editable package. `#4335 <https://github.com/pypa/pipenv/issues/4335>`_
|
||||
- Fix a bug that ``setup.py`` can't be parsed correctly when the assignment is type-annotated. `#4342 <https://github.com/pypa/pipenv/issues/4342>`_
|
||||
- Fix a bug that ``pipenv graph`` throws an exception that PipenvCmdError(cmd_string, c.out, c.err, return_code). `#4388 <https://github.com/pypa/pipenv/issues/4388>`_
|
||||
- Do not copy the whole directory tree of local file package. `#4403 <https://github.com/pypa/pipenv/issues/4403>`_
|
||||
- Correctly detect whether Pipenv in run under an activated virtualenv. `#4412 <https://github.com/pypa/pipenv/issues/4412>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Update ``requirementslib`` to ``1.5.12``. `#4385 <https://github.com/pypa/pipenv/issues/4385>`_
|
||||
- * Update ``requirements`` to ``1.5.13``.
|
||||
* Update ``pip-shims`` to ``0.5.3``. `#4421 <https://github.com/pypa/pipenv/issues/4421>`_
|
||||
|
||||
|
||||
2020.6.2 (2020-06-02)
|
||||
=====================
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- Pipenv will now detect existing ``venv`` and ``virtualenv`` based virtual environments more robustly. `#4276 <https://github.com/pypa/pipenv/issues/4276>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- ``+`` signs in URL authentication fragments will no longer be incorrectly replaced with space ( `` `` ) characters. `#4271 <https://github.com/pypa/pipenv/issues/4271>`_
|
||||
- Fixed a regression which caused Pipenv to fail when running under ``/``. `#4273 <https://github.com/pypa/pipenv/issues/4273>`_
|
||||
- ``setup.py`` files with ``version`` variables read from ``os.environ`` are now able to be parsed successfully. `#4274 <https://github.com/pypa/pipenv/issues/4274>`_
|
||||
- Fixed a bug which caused Pipenv to fail to install packages in a virtual environment if those packages were already present in the system global environment. `#4276 <https://github.com/pypa/pipenv/issues/4276>`_
|
||||
- Fix a bug that caused non-specific versions to be pinned in ``Pipfile.lock``. `#4278 <https://github.com/pypa/pipenv/issues/4278>`_
|
||||
- Corrected a missing exception import and invalid function call invocations in ``pipenv.cli.command``. `#4286 <https://github.com/pypa/pipenv/issues/4286>`_
|
||||
- Fixed an issue with resolving packages with names defined by function calls in ``setup.py``. `#4292 <https://github.com/pypa/pipenv/issues/4292>`_
|
||||
- Fixed a regression with installing the current directory, or ``.``, inside a ``venv`` based virtual environment. `#4295 <https://github.com/pypa/pipenv/issues/4295>`_
|
||||
- Fixed a bug with the discovery of python paths on Windows which could prevent installation of environments during ``pipenv install``. `#4296 <https://github.com/pypa/pipenv/issues/4296>`_
|
||||
- Fixed an issue in the ``requirementslib`` AST parser which prevented parsing of ``setup.py`` files for dependency metadata. `#4298 <https://github.com/pypa/pipenv/issues/4298>`_
|
||||
- Fix a bug where Pipenv doesn't realize the session is interactive `#4305 <https://github.com/pypa/pipenv/issues/4305>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Updated requirementslib to version ``1.5.11``. `#4292 <https://github.com/pypa/pipenv/issues/4292>`_
|
||||
- Updated vendored dependencies:
|
||||
- **pythonfinder**: ``1.2.2`` => ``1.2.4``
|
||||
- **requirementslib**: ``1.5.9`` => ``1.5.10`` `#4302 <https://github.com/pypa/pipenv/issues/4302>`_
|
||||
|
||||
|
||||
2020.5.28 (2020-05-28)
|
||||
======================
|
||||
|
||||
Features & Improvements
|
||||
-----------------------
|
||||
|
||||
- ``pipenv install`` and ``pipenv sync`` will no longer attempt to install satisfied dependencies during installation. `#3057 <https://github.com/pypa/pipenv/issues/3057>`_,
|
||||
`#3506 <https://github.com/pypa/pipenv/issues/3506>`_
|
||||
- Added support for resolution of direct-url dependencies in ``setup.py`` files to respect ``PEP-508`` style URL dependencies. `#3148 <https://github.com/pypa/pipenv/issues/3148>`_
|
||||
- Added full support for resolution of all dependency types including direct URLs, zip archives, tarballs, etc.
|
||||
|
||||
- Improved error handling and formatting.
|
||||
|
||||
- Introduced improved cross platform stream wrappers for better ``stdout`` and ``stderr`` consistency. `#3298 <https://github.com/pypa/pipenv/issues/3298>`_
|
||||
- For consistency with other commands and the ``--dev`` option
|
||||
description, ``pipenv lock --requirements --dev`` now emits
|
||||
both default and development dependencies.
|
||||
The new ``--dev-only`` option requests the previous
|
||||
behaviour (e.g. to generate a ``dev-requirements.txt`` file). `#3316 <https://github.com/pypa/pipenv/issues/3316>`_
|
||||
- Pipenv will now successfully recursively lock VCS sub-dependencies. `#3328 <https://github.com/pypa/pipenv/issues/3328>`_
|
||||
- Added support for ``--verbose`` output to ``pipenv run``. `#3348 <https://github.com/pypa/pipenv/issues/3348>`_
|
||||
- Pipenv will now discover and resolve the intrinsic dependencies of **all** VCS dependencies, whether they are editable or not, to prevent resolution conflicts. `#3368 <https://github.com/pypa/pipenv/issues/3368>`_
|
||||
- Added a new environment variable, ``PIPENV_RESOLVE_VCS``, to toggle dependency resolution off for non-editable VCS, file, and URL based dependencies. `#3577 <https://github.com/pypa/pipenv/issues/3577>`_
|
||||
- Added the ability for Windows users to enable emojis by setting ``PIPENV_HIDE_EMOJIS=0``. `#3595 <https://github.com/pypa/pipenv/issues/3595>`_
|
||||
- Allow overriding PIPENV_INSTALL_TIMEOUT environment variable (in seconds). `#3652 <https://github.com/pypa/pipenv/issues/3652>`_
|
||||
- Allow overriding PIP_EXISTS_ACTION evironment variable (value is passed to pip install).
|
||||
Possible values here: https://pip.pypa.io/en/stable/reference/pip/#exists-action-option
|
||||
Useful when you need to `PIP_EXISTS_ACTION=i` (ignore existing packages) - great for CI environments, where you need really fast setup. `#3738 <https://github.com/pypa/pipenv/issues/3738>`_
|
||||
- Pipenv will no longer forcibly override ``PIP_NO_DEPS`` on all vcs and file dependencies as resolution happens on these in a pre-lock step. `#3763 <https://github.com/pypa/pipenv/issues/3763>`_
|
||||
- Improved verbose logging output during ``pipenv lock`` will now stream output to the console while maintaining a spinner. `#3810 <https://github.com/pypa/pipenv/issues/3810>`_
|
||||
- Added support for automatic python installs via ``asdf`` and associated ``PIPENV_DONT_USE_ASDF`` environment variable. `#4018 <https://github.com/pypa/pipenv/issues/4018>`_
|
||||
- Pyenv/asdf can now be used whether or not they are available on PATH. Setting PYENV_ROOT/ASDF_DIR in a Pipenv's .env allows Pipenv to install an interpreter without any shell customizations, so long as pyenv/asdf is installed. `#4245 <https://github.com/pypa/pipenv/issues/4245>`_
|
||||
- Added ``--key`` command line parameter for including personal PyUp.io API tokens when running ``pipenv check``. `#4257 <https://github.com/pypa/pipenv/issues/4257>`_
|
||||
|
||||
Behavior Changes
|
||||
----------------
|
||||
|
||||
- Make conservative checks of known exceptions when subprocess returns output, so user won't see the whole traceback - just the error. `#2553 <https://github.com/pypa/pipenv/issues/2553>`_
|
||||
- Do not touch Pipfile early and rely on it so that one can do ``pipenv sync`` without a Pipfile. `#3386 <https://github.com/pypa/pipenv/issues/3386>`_
|
||||
- Re-enable ``--help`` option for ``pipenv run`` command. `#3844 <https://github.com/pypa/pipenv/issues/3844>`_
|
||||
- Make sure ``pipenv lock -r --pypi-mirror {MIRROR_URL}`` will respect the pypi-mirror in requirements output. `#4199 <https://github.com/pypa/pipenv/issues/4199>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Raise `PipenvUsageError` when [[source]] does not contain url field. `#2373 <https://github.com/pypa/pipenv/issues/2373>`_
|
||||
- Fixed a bug which caused editable package resolution to sometimes fail with an unhelpful setuptools-related error message. `#2722 <https://github.com/pypa/pipenv/issues/2722>`_
|
||||
- Fixed an issue which caused errors due to reliance on the system utilities ``which`` and ``where`` which may not always exist on some systems.
|
||||
- Fixed a bug which caused periodic failures in python discovery when executables named ``python`` were not present on the target ``$PATH``. `#2783 <https://github.com/pypa/pipenv/issues/2783>`_
|
||||
- Dependency resolution now writes hashes for local and remote files to the lockfile. `#3053 <https://github.com/pypa/pipenv/issues/3053>`_
|
||||
- Fixed a bug which prevented ``pipenv graph`` from correctly showing all dependencies when running from within ``pipenv shell``. `#3071 <https://github.com/pypa/pipenv/issues/3071>`_
|
||||
- Fixed resolution of direct-url dependencies in ``setup.py`` files to respect ``PEP-508`` style URL dependencies. `#3148 <https://github.com/pypa/pipenv/issues/3148>`_
|
||||
- Fixed a bug which caused failures in warning reporting when running pipenv inside a virtualenv under some circumstances.
|
||||
|
||||
- Fixed a bug with package discovery when running ``pipenv clean``. `#3298 <https://github.com/pypa/pipenv/issues/3298>`_
|
||||
- Quote command arguments with carets (``^``) on Windows to work around unintended shell escapes. `#3307 <https://github.com/pypa/pipenv/issues/3307>`_
|
||||
- Handle alternate names for UTF-8 encoding. `#3313 <https://github.com/pypa/pipenv/issues/3313>`_
|
||||
- Abort pipenv before adding the non-exist package to Pipfile. `#3318 <https://github.com/pypa/pipenv/issues/3318>`_
|
||||
- Don't normalize the package name user passes in. `#3324 <https://github.com/pypa/pipenv/issues/3324>`_
|
||||
- Fix a bug where custom virtualenv can not be activated with pipenv shell `#3339 <https://github.com/pypa/pipenv/issues/3339>`_
|
||||
- Fix a bug that ``--site-packages`` flag is not recognized. `#3351 <https://github.com/pypa/pipenv/issues/3351>`_
|
||||
- Fix a bug where pipenv --clear is not working `#3353 <https://github.com/pypa/pipenv/issues/3353>`_
|
||||
- Fix unhashable type error during ``$ pipenv install --selective-upgrade`` `#3384 <https://github.com/pypa/pipenv/issues/3384>`_
|
||||
- Dependencies with direct ``PEP508`` compliant VCS URLs specified in their ``install_requires`` will now be successfully locked during the resolution process. `#3396 <https://github.com/pypa/pipenv/issues/3396>`_
|
||||
- Fixed a keyerror which could occur when locking VCS dependencies in some cases. `#3404 <https://github.com/pypa/pipenv/issues/3404>`_
|
||||
- Fixed a bug that ``ValidationError`` is thrown when some fields are missing in source section. `#3427 <https://github.com/pypa/pipenv/issues/3427>`_
|
||||
- Updated the index names in lock file when source name in Pipfile is changed. `#3449 <https://github.com/pypa/pipenv/issues/3449>`_
|
||||
- Fixed an issue which caused ``pipenv install --help`` to show duplicate entries for ``--pre``. `#3479 <https://github.com/pypa/pipenv/issues/3479>`_
|
||||
- Fix bug causing ``[SSL: CERTIFICATE_VERIFY_FAILED]`` when Pipfile ``[[source]]`` has verify_ssl=false and url with custom port. `#3502 <https://github.com/pypa/pipenv/issues/3502>`_
|
||||
- Fix ``sync --sequential`` ignoring ``pip install`` errors and logs. `#3537 <https://github.com/pypa/pipenv/issues/3537>`_
|
||||
- Fix the issue that lock file can't be created when ``PIPENV_PIPFILE`` is not under working directory. `#3584 <https://github.com/pypa/pipenv/issues/3584>`_
|
||||
- Pipenv will no longer inadvertently set ``editable=True`` on all vcs dependencies. `#3647 <https://github.com/pypa/pipenv/issues/3647>`_
|
||||
- The ``--keep-outdated`` argument to ``pipenv install`` and ``pipenv lock`` will now drop specifier constraints when encountering editable dependencies.
|
||||
- In addition, ``--keep-outdated`` will retain specifiers that would otherwise be dropped from any entries that have not been updated. `#3656 <https://github.com/pypa/pipenv/issues/3656>`_
|
||||
- Fixed a bug which sometimes caused pipenv to fail to respect the ``--site-packages`` flag when passed with ``pipenv install``. `#3718 <https://github.com/pypa/pipenv/issues/3718>`_
|
||||
- Normalize the package names to lowercase when comparing used and in-Pipfile packages. `#3745 <https://github.com/pypa/pipenv/issues/3745>`_
|
||||
- ``pipenv update --outdated`` will now correctly handle comparisons between pre/post-releases and normal releases. `#3766 <https://github.com/pypa/pipenv/issues/3766>`_
|
||||
- Fixed a ``KeyError`` which could occur when pinning outdated VCS dependencies via ``pipenv lock --keep-outdated``. `#3768 <https://github.com/pypa/pipenv/issues/3768>`_
|
||||
- Resolved an issue which caused resolution to fail when encountering poorly formatted ``python_version`` markers in ``setup.py`` and ``setup.cfg`` files. `#3786 <https://github.com/pypa/pipenv/issues/3786>`_
|
||||
- Fix a bug that installation errors are displayed as a list. `#3794 <https://github.com/pypa/pipenv/issues/3794>`_
|
||||
- Update ``pythonfinder`` to fix a problem that ``python.exe`` will be mistakenly chosen for
|
||||
virtualenv creation under WSL. `#3807 <https://github.com/pypa/pipenv/issues/3807>`_
|
||||
- Fixed several bugs which could prevent editable VCS dependencies from being installed into target environments, even when reporting successful installation. `#3809 <https://github.com/pypa/pipenv/issues/3809>`_
|
||||
- ``pipenv check --system`` should find the correct Python interpreter when ``python`` does not exist on the system. `#3819 <https://github.com/pypa/pipenv/issues/3819>`_
|
||||
- Resolve the symlinks when the path is absolute. `#3842 <https://github.com/pypa/pipenv/issues/3842>`_
|
||||
- Pass ``--pre`` and ``--clear`` options to ``pipenv update --outdated``. `#3879 <https://github.com/pypa/pipenv/issues/3879>`_
|
||||
- Fixed a bug which prevented resolution of direct URL dependencies which have PEP508 style direct url VCS sub-dependencies with subdirectories. `#3976 <https://github.com/pypa/pipenv/issues/3976>`_
|
||||
- Honor PIPENV_SPINNER environment variable `#4045 <https://github.com/pypa/pipenv/issues/4045>`_
|
||||
- Fixed an issue with ``pipenv check`` failing due to an invalid API key from ``pyup.io``. `#4188 <https://github.com/pypa/pipenv/issues/4188>`_
|
||||
- Fixed a bug which caused versions from VCS dependencies to be included in ``Pipfile.lock`` inadvertently. `#4217 <https://github.com/pypa/pipenv/issues/4217>`_
|
||||
- Fixed a bug which caused pipenv to search non-existent virtual environments for ``pip`` when installing using ``--system``. `#4220 <https://github.com/pypa/pipenv/issues/4220>`_
|
||||
- ``Requires-Python`` values specifying constraint versions of python starting from ``1.x`` will now be parsed successfully. `#4226 <https://github.com/pypa/pipenv/issues/4226>`_
|
||||
- Fix a bug of ``pipenv update --outdated`` that can't print output correctly. `#4229 <https://github.com/pypa/pipenv/issues/4229>`_
|
||||
- Fixed a bug which caused pipenv to prefer source distributions over wheels from ``PyPI`` during the dependency resolution phase.
|
||||
Fixed an issue which prevented proper build isolation using ``pep517`` based builders during dependency resolution. `#4231 <https://github.com/pypa/pipenv/issues/4231>`_
|
||||
- Don't fallback to system Python when no matching Python version is found. `#4232 <https://github.com/pypa/pipenv/issues/4232>`_
|
||||
|
||||
Vendored Libraries
|
||||
------------------
|
||||
|
||||
- Updated vendored dependencies:
|
||||
|
||||
- **attrs**: ``18.2.0`` => ``19.1.0``
|
||||
- **certifi**: ``2018.10.15`` => ``2019.3.9``
|
||||
- **cached_property**: ``1.4.3`` => ``1.5.1``
|
||||
- **cerberus**: ``1.2.0`` => ``1.3.1``
|
||||
- **click-completion**: ``0.5.0`` => ``0.5.1``
|
||||
- **colorama**: ``0.3.9`` => ``0.4.1``
|
||||
- **distlib**: ``0.2.8`` => ``0.2.9``
|
||||
- **idna**: ``2.7`` => ``2.8``
|
||||
- **jinja2**: ``2.10.0`` => ``2.10.1``
|
||||
- **markupsafe**: ``1.0`` => ``1.1.1``
|
||||
- **orderedmultidict**: ``(new)`` => ``1.0``
|
||||
- **packaging**: ``18.0`` => ``19.0``
|
||||
- **parse**: ``1.9.0`` => ``1.12.0``
|
||||
- **pathlib2**: ``2.3.2`` => ``2.3.3``
|
||||
- **pep517**: ``(new)`` => ``0.5.0``
|
||||
- **pexpect**: ``4.6.0`` => ``4.7.0``
|
||||
- **pipdeptree**: ``0.13.0`` => ``0.13.2``
|
||||
- **pyparsing**: ``2.2.2`` => ``2.3.1``
|
||||
- **python-dotenv**: ``0.9.1`` => ``0.10.2``
|
||||
- **pythonfinder**: ``1.1.10`` => ``1.2.1``
|
||||
- **pytoml**: ``(new)`` => ``0.1.20``
|
||||
- **requests**: ``2.20.1`` => ``2.21.0``
|
||||
- **requirementslib**: ``1.3.3`` => ``1.5.0``
|
||||
- **scandir**: ``1.9.0`` => ``1.10.0``
|
||||
- **shellingham**: ``1.2.7`` => ``1.3.1``
|
||||
- **six**: ``1.11.0`` => ``1.12.0``
|
||||
- **tomlkit**: ``0.5.2`` => ``0.5.3``
|
||||
- **urllib3**: ``1.24`` => ``1.25.2``
|
||||
- **vistir**: ``0.3.0`` => ``0.4.1``
|
||||
- **yaspin**: ``0.14.0`` => ``0.14.3``
|
||||
|
||||
- Removed vendored dependency **cursor**. `#3298 <https://github.com/pypa/pipenv/issues/3298>`_
|
||||
- Updated ``pip_shims`` to support ``--outdated`` with new pip versions. `#3766 <https://github.com/pypa/pipenv/issues/3766>`_
|
||||
- Update vendored dependencies and invocations
|
||||
|
||||
- Update vendored and patched dependencies
|
||||
- Update patches on ``piptools``, ``pip``, ``pip-shims``, ``tomlkit`
|
||||
- Fix invocations of dependencies
|
||||
- Fix custom ``InstallCommand` instantiation
|
||||
- Update ``PackageFinder` usage
|
||||
- Fix ``Bool` stringify attempts from ``tomlkit`
|
||||
|
||||
Updated vendored dependencies:
|
||||
- **attrs**: ```18.2.0`` => ```19.1.0``
|
||||
- **certifi**: ```2018.10.15`` => ```2019.3.9``
|
||||
- **cached_property**: ```1.4.3`` => ```1.5.1``
|
||||
- **cerberus**: ```1.2.0`` => ```1.3.1``
|
||||
- **click**: ```7.0.0`` => ```7.1.1``
|
||||
- **click-completion**: ```0.5.0`` => ```0.5.1``
|
||||
- **colorama**: ```0.3.9`` => ```0.4.3``
|
||||
- **contextlib2**: ```(new)`` => ```0.6.0.post1``
|
||||
- **distlib**: ```0.2.8`` => ```0.2.9``
|
||||
- **funcsigs**: ```(new)`` => ```1.0.2``
|
||||
- **importlib_metadata** ```1.3.0`` => ```1.5.1``
|
||||
- **importlib-resources**: ```(new)`` => ```1.4.0``
|
||||
- **idna**: ```2.7`` => ```2.9``
|
||||
- **jinja2**: ```2.10.0`` => ```2.11.1``
|
||||
- **markupsafe**: ```1.0`` => ```1.1.1``
|
||||
- **more-itertools**: ```(new)`` => ```5.0.0``
|
||||
- **orderedmultidict**: ```(new)`` => ```1.0``
|
||||
- **packaging**: ```18.0`` => ```19.0``
|
||||
- **parse**: ```1.9.0`` => ```1.15.0``
|
||||
- **pathlib2**: ```2.3.2`` => ```2.3.3``
|
||||
- **pep517**: ```(new)`` => ```0.5.0``
|
||||
- **pexpect**: ```4.6.0`` => ```4.8.0``
|
||||
- **pip-shims**: ```0.2.0`` => ```0.5.1``
|
||||
- **pipdeptree**: ```0.13.0`` => ```0.13.2``
|
||||
- **pyparsing**: ```2.2.2`` => ```2.4.6``
|
||||
- **python-dotenv**: ```0.9.1`` => ```0.10.2``
|
||||
- **pythonfinder**: ```1.1.10`` => ```1.2.2``
|
||||
- **pytoml**: ```(new)`` => ```0.1.20``
|
||||
- **requests**: ```2.20.1`` => ```2.23.0``
|
||||
- **requirementslib**: ```1.3.3`` => ```1.5.4``
|
||||
- **scandir**: ```1.9.0`` => ```1.10.0``
|
||||
- **shellingham**: ```1.2.7`` => ```1.3.2``
|
||||
- **six**: ```1.11.0`` => ```1.14.0``
|
||||
- **tomlkit**: ```0.5.2`` => ```0.5.11``
|
||||
- **urllib3**: ```1.24`` => ```1.25.8``
|
||||
- **vistir**: ```0.3.0`` => ```0.5.0``
|
||||
- **yaspin**: ```0.14.0`` => ```0.14.3``
|
||||
- **zipp**: ```0.6.0``
|
||||
|
||||
- Removed vendored dependency **cursor**. `#4169 <https://github.com/pypa/pipenv/issues/4169>`_
|
||||
- Add and update vendored dependencies to accommodate ``safety`` vendoring:
|
||||
- **safety** ``(none)`` => ``1.8.7``
|
||||
- **dparse** ``(none)`` => ``0.5.0``
|
||||
- **pyyaml** ``(none)`` => ``5.3.1``
|
||||
- **urllib3** ``1.25.8`` => ``1.25.9``
|
||||
- **certifi** ``2019.11.28`` => ``2020.4.5.1``
|
||||
- **pyparsing** ``2.4.6`` => ``2.4.7``
|
||||
- **resolvelib** ``0.2.2`` => ``0.3.0``
|
||||
- **importlib-metadata** ``1.5.1`` => ``1.6.0``
|
||||
- **pip-shims** ``0.5.1`` => ``0.5.2``
|
||||
- **requirementslib** ``1.5.5`` => ``1.5.6`` `#4188 <https://github.com/pypa/pipenv/issues/4188>`_
|
||||
- Updated vendored ``pip`` => ``20.0.2`` and ``pip-tools`` => ``5.0.0``. `#4215 <https://github.com/pypa/pipenv/issues/4215>`_
|
||||
- Updated vendored dependencies to latest versions for security and bug fixes:
|
||||
|
||||
- **requirementslib** ``1.5.8`` => ``1.5.9``
|
||||
- **vistir** ``0.5.0`` => ``0.5.1``
|
||||
- **jinja2** ``2.11.1`` => ``2.11.2``
|
||||
- **click** ``7.1.1`` => ``7.1.2``
|
||||
- **dateutil** ``(none)`` => ``2.8.1``
|
||||
- **backports.functools_lru_cache** ``1.5.0`` => ``1.6.1``
|
||||
- **enum34** ``1.1.6`` => ``1.1.10``
|
||||
- **toml** ``0.10.0`` => ``0.10.1``
|
||||
- **importlib_resources** ``1.4.0`` => ``1.5.0`` `#4226 <https://github.com/pypa/pipenv/issues/4226>`_
|
||||
- Changed attrs import path in vendored dependencies to always import from ``pipenv.vendor``. `#4267 <https://github.com/pypa/pipenv/issues/4267>`_
|
||||
|
||||
Improved Documentation
|
||||
----------------------
|
||||
|
||||
- Added documenation about variable expansion in ``Pipfile`` entries. `#2317 <https://github.com/pypa/pipenv/issues/2317>`_
|
||||
- Consolidate all contributing docs in the rst file `#3120 <https://github.com/pypa/pipenv/issues/3120>`_
|
||||
- Update the out-dated manual page. `#3246 <https://github.com/pypa/pipenv/issues/3246>`_
|
||||
- Move CLI docs to its own page. `#3346 <https://github.com/pypa/pipenv/issues/3346>`_
|
||||
- Replace (non-existant) video on docs index.rst with equivalent gif. `#3499 <https://github.com/pypa/pipenv/issues/3499>`_
|
||||
- Clarify wording in Basic Usage example on using double quotes to escape shell redirection `#3522 <https://github.com/pypa/pipenv/issues/3522>`_
|
||||
- Ensure docs show navigation on small-screen devices `#3527 <https://github.com/pypa/pipenv/issues/3527>`_
|
||||
- Added a link to the TOML Spec under General Recommendations & Version Control to clarify how Pipfiles should be written. `#3629 <https://github.com/pypa/pipenv/issues/3629>`_
|
||||
- Updated the documentation with the new ``pytest`` entrypoint. `#3759 <https://github.com/pypa/pipenv/issues/3759>`_
|
||||
- Fix link to GIF in README.md demonstrating Pipenv's usage, and add descriptive alt text. `#3911 <https://github.com/pypa/pipenv/issues/3911>`_
|
||||
- Added a line describing potential issues in fancy extension. `#3912 <https://github.com/pypa/pipenv/issues/3912>`_
|
||||
- Documental description of how Pipfile works and association with Pipenv. `#3913 <https://github.com/pypa/pipenv/issues/3913>`_
|
||||
- Clarify the proper value of ``python_version`` and ``python_full_version``. `#3914 <https://github.com/pypa/pipenv/issues/3914>`_
|
||||
- Write description for --deploy extension and few extensions differences. `#3915 <https://github.com/pypa/pipenv/issues/3915>`_
|
||||
- More documentation for ``.env`` files `#4100 <https://github.com/pypa/pipenv/issues/4100>`_
|
||||
- Updated documentation to point to working links. `#4137 <https://github.com/pypa/pipenv/issues/4137>`_
|
||||
- Replace docs.pipenv.org with pipenv.pypa.io `#4167 <https://github.com/pypa/pipenv/issues/4167>`_
|
||||
- Added functionality to check spelling in documentation and cleaned up existing typographical issues. `#4209 <https://github.com/pypa/pipenv/issues/4209>`_
|
||||
|
||||
|
||||
2018.11.26 (2018-11-26)
|
||||
=======================
|
||||
|
||||
@@ -10,14 +557,14 @@ Bug Fixes
|
||||
- Fixed a bug which could cause failures to occur when parsing python entries from global pyenv version files. `#3224 <https://github.com/pypa/pipenv/issues/3224>`_
|
||||
- Fixed an issue which prevented the parsing of named extras sections from certain ``setup.py`` files. `#3230 <https://github.com/pypa/pipenv/issues/3230>`_
|
||||
- Correctly detect the virtualenv location inside an activated virtualenv. `#3231 <https://github.com/pypa/pipenv/issues/3231>`_
|
||||
- Fixed a bug which caused spinner frames to be written to stdout during locking operations which could cause redirection pipes to fail. `#3239 <https://github.com/pypa/pipenv/issues/3239>`_
|
||||
- Fixed a bug that editable pacakges can't be uninstalled correctly. `#3240 <https://github.com/pypa/pipenv/issues/3240>`_
|
||||
- Fixed a bug which caused spinner frames to be written to standard output during locking operations which could cause redirection pipes to fail. `#3239 <https://github.com/pypa/pipenv/issues/3239>`_
|
||||
- Fixed a bug that editable packages can't be uninstalled correctly. `#3240 <https://github.com/pypa/pipenv/issues/3240>`_
|
||||
- Corrected an issue with installation timeouts which caused dependency resolution to fail for longer duration resolution steps. `#3244 <https://github.com/pypa/pipenv/issues/3244>`_
|
||||
- Adding normal pep 508 compatible markers is now fully functional when using VCS dependencies. `#3249 <https://github.com/pypa/pipenv/issues/3249>`_
|
||||
- Updated ``requirementslib`` and ``pythonfinder`` for multiple bugfixes. `#3254 <https://github.com/pypa/pipenv/issues/3254>`_
|
||||
- Updated ``requirementslib`` and ``pythonfinder`` for multiple bug fixes. `#3254 <https://github.com/pypa/pipenv/issues/3254>`_
|
||||
- Pipenv will now ignore hashes when installing with ``--skip-lock``. `#3255 <https://github.com/pypa/pipenv/issues/3255>`_
|
||||
- Fixed an issue where pipenv could crash when multiple pipenv processes attempted to create the same directory. `#3257 <https://github.com/pypa/pipenv/issues/3257>`_
|
||||
- Fixed an issue which sometimes prevented successful creation of project pipfiles. `#3260 <https://github.com/pypa/pipenv/issues/3260>`_
|
||||
- Fixed an issue which sometimes prevented successful creation of a project Pipfile. `#3260 <https://github.com/pypa/pipenv/issues/3260>`_
|
||||
- ``pipenv install`` will now unset the ``PYTHONHOME`` environment variable when not combined with ``--system``. `#3261 <https://github.com/pypa/pipenv/issues/3261>`_
|
||||
- Pipenv will ensure that warnings do not interfere with the resolution process by suppressing warnings' usage of standard output and writing to standard error instead. `#3273 <https://github.com/pypa/pipenv/issues/3273>`_
|
||||
- Fixed an issue which prevented variables from the environment, such as ``PIPENV_DEV`` or ``PIPENV_SYSTEM``, from being parsed and implemented correctly. `#3278 <https://github.com/pypa/pipenv/issues/3278>`_
|
||||
@@ -43,16 +590,16 @@ Features & Improvements
|
||||
- Improved exceptions and error handling on failures. `#1977 <https://github.com/pypa/pipenv/issues/1977>`_
|
||||
- Added persistent settings for all CLI flags via ``PIPENV_{FLAG_NAME}`` environment variables by enabling ``auto_envvar_prefix=PIPENV`` in click (implements PEEP-0002). `#2200 <https://github.com/pypa/pipenv/issues/2200>`_
|
||||
- Added improved messaging about available but skipped updates due to dependency conflicts when running ``pipenv update --outdated``. `#2411 <https://github.com/pypa/pipenv/issues/2411>`_
|
||||
- Added environment variable `PIPENV_PYUP_API_KEY` to add ability
|
||||
to override the bundled pyup.io API key. `#2825 <https://github.com/pypa/pipenv/issues/2825>`_
|
||||
- Added additional output to ``pipenv update --outdated`` to indicate that the operation succeded and all packages were already up to date. `#2828 <https://github.com/pypa/pipenv/issues/2828>`_
|
||||
- Added environment variable ``PIPENV_PYUP_API_KEY`` to add ability
|
||||
to override the bundled PyUP.io API key. `#2825 <https://github.com/pypa/pipenv/issues/2825>`_
|
||||
- Added additional output to ``pipenv update --outdated`` to indicate that the operation succeeded and all packages were already up to date. `#2828 <https://github.com/pypa/pipenv/issues/2828>`_
|
||||
- Updated ``crayons`` patch to enable colors on native powershell but swap native blue for magenta. `#3020 <https://github.com/pypa/pipenv/issues/3020>`_
|
||||
- Added support for ``--bare`` to ``pipenv clean``, and fixed ``pipenv sync --bare`` to actually reduce output. `#3041 <https://github.com/pypa/pipenv/issues/3041>`_
|
||||
- Added windows-compatible spinner via upgraded ``vistir`` dependency. `#3089 <https://github.com/pypa/pipenv/issues/3089>`_
|
||||
- - Added support for python installations managed by ``asdf``. `#3096 <https://github.com/pypa/pipenv/issues/3096>`_
|
||||
- Improved runtime performance of no-op commands such as ``pipenv --venv`` by around 2/3. `#3158 <https://github.com/pypa/pipenv/issues/3158>`_
|
||||
- Do not show error but success for running ``pipenv uninstall --all`` in a fresh virtual environment. `#3170 <https://github.com/pypa/pipenv/issues/3170>`_
|
||||
- Improved asynchronous installation and error handling via queued subprocess paralleization. `#3217 <https://github.com/pypa/pipenv/issues/3217>`_
|
||||
- Improved asynchronous installation and error handling via queued subprocess parallelization. `#3217 <https://github.com/pypa/pipenv/issues/3217>`_
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
@@ -60,7 +607,7 @@ Bug Fixes
|
||||
- Remote non-PyPI artifacts and local wheels and artifacts will now include their own hashes rather than including hashes from ``PyPI``. `#2394 <https://github.com/pypa/pipenv/issues/2394>`_
|
||||
- Non-ascii characters will now be handled correctly when parsed by pipenv's ``ToML`` parsers. `#2737 <https://github.com/pypa/pipenv/issues/2737>`_
|
||||
- Updated ``pipenv uninstall`` to respect the ``--skip-lock`` argument. `#2848 <https://github.com/pypa/pipenv/issues/2848>`_
|
||||
- Fixed a bug which caused uninstallation to sometimes fail to successfullly remove packages from ``Pipfiles`` with comments on preceding or following lines. `#2885 <https://github.com/pypa/pipenv/issues/2885>`_,
|
||||
- Fixed a bug which caused uninstallation to sometimes fail to successfully remove packages from ``Pipfiles`` with comments on preceding or following lines. `#2885 <https://github.com/pypa/pipenv/issues/2885>`_,
|
||||
`#3099 <https://github.com/pypa/pipenv/issues/3099>`_
|
||||
- Pipenv will no longer fail when encountering python versions on Windows that have been uninstalled. `#2983 <https://github.com/pypa/pipenv/issues/2983>`_
|
||||
- Fixed unnecessary extras are added when translating markers `#3026 <https://github.com/pypa/pipenv/issues/3026>`_
|
||||
@@ -79,7 +626,7 @@ Bug Fixes
|
||||
- Fixed an issue which caused ``pipenv clean`` to sometimes clean packages from the base ``site-packages`` folder or fail entirely. `#3113 <https://github.com/pypa/pipenv/issues/3113>`_
|
||||
- Updated ``pythonfinder`` to correct an issue with unnesting of nested paths when searching for python versions. `#3121 <https://github.com/pypa/pipenv/issues/3121>`_
|
||||
- Added additional logic for ignoring and replacing non-ascii characters when formatting console output on non-UTF-8 systems. `#3131 <https://github.com/pypa/pipenv/issues/3131>`_
|
||||
- Fix virtual environment discovery when `PIPENV_VENV_IN_PROJECT` is set, but the in-project `.venv` is a file. `#3134 <https://github.com/pypa/pipenv/issues/3134>`_
|
||||
- Fix virtual environment discovery when ``PIPENV_VENV_IN_PROJECT`` is set, but the in-project `.venv` is a file. `#3134 <https://github.com/pypa/pipenv/issues/3134>`_
|
||||
- Hashes for remote and local non-PyPI artifacts will now be included in ``Pipfile.lock`` during resolution. `#3145 <https://github.com/pypa/pipenv/issues/3145>`_
|
||||
- Fix project path hashing logic in purpose to prevent collisions of virtual environments. `#3151 <https://github.com/pypa/pipenv/issues/3151>`_
|
||||
- Fix package installation when the virtual environment path contains parentheses. `#3158 <https://github.com/pypa/pipenv/issues/3158>`_
|
||||
@@ -166,7 +713,7 @@ Features & Improvements
|
||||
- Added environment variables `PIPENV_VERBOSE` and `PIPENV_QUIET` to control
|
||||
output verbosity without needing to pass options. `#2527 <https://github.com/pypa/pipenv/issues/2527>`_
|
||||
|
||||
- Updated test-pypi addon to better support json-api access (forward compatibility).
|
||||
- Updated test-PyPI add-on to better support json-API access (forward compatibility).
|
||||
Improved testing process for new contributors. `#2568 <https://github.com/pypa/pipenv/issues/2568>`_
|
||||
|
||||
- Greatly enhanced python discovery functionality:
|
||||
@@ -202,11 +749,11 @@ Behavior Changes
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fixed a bug which prevented installation of editable requirements using ``ssh://`` style urls `#1393 <https://github.com/pypa/pipenv/issues/1393>`_
|
||||
- Fixed a bug which prevented installation of editable requirements using ``ssh://`` style URLs `#1393 <https://github.com/pypa/pipenv/issues/1393>`_
|
||||
|
||||
- VCS Refs for locked local editable dependencies will now update appropriately to the latest hash when running ``pipenv update``. `#1690 <https://github.com/pypa/pipenv/issues/1690>`_
|
||||
|
||||
- ``.tar.gz`` and ``.zip`` artifacts will now have dependencies installed even when they are missing from the lockfile. `#2173 <https://github.com/pypa/pipenv/issues/2173>`_
|
||||
- ``.tar.gz`` and ``.zip`` artifacts will now have dependencies installed even when they are missing from the Lockfile. `#2173 <https://github.com/pypa/pipenv/issues/2173>`_
|
||||
|
||||
- The command line parser will now handle multiple ``-e/--editable`` dependencies properly via click's option parser to help mitigate future parsing issues. `#2279 <https://github.com/pypa/pipenv/issues/2279>`_
|
||||
|
||||
@@ -230,12 +777,12 @@ Bug Fixes
|
||||
|
||||
- Fix subshell invocation on Windows for Python 2. `#2515 <https://github.com/pypa/pipenv/issues/2515>`_
|
||||
|
||||
- Fixed a bug which sometimes caused pipenv to throw a ``TypeError`` or to run into encoding issues when writing lockfiles on python 2. `#2561 <https://github.com/pypa/pipenv/issues/2561>`_
|
||||
- Fixed a bug which sometimes caused pipenv to throw a ``TypeError`` or to run into encoding issues when writing a Lockfile on python 2. `#2561 <https://github.com/pypa/pipenv/issues/2561>`_
|
||||
|
||||
- Improve quoting logic for ``pipenv run`` so it works better with Windows
|
||||
built-in commands. `#2563 <https://github.com/pypa/pipenv/issues/2563>`_
|
||||
|
||||
- Fixed a bug related to parsing vcs requirements with both extras and subdirectory fragments.
|
||||
- Fixed a bug related to parsing VCS requirements with both extras and subdirectory fragments.
|
||||
Corrected an issue in the ``requirementslib`` parser which led to some markers being discarded rather than evaluated. `#2564 <https://github.com/pypa/pipenv/issues/2564>`_
|
||||
|
||||
- Fixed multiple issues with finding the correct system python locations. `#2582 <https://github.com/pypa/pipenv/issues/2582>`_
|
||||
@@ -264,7 +811,7 @@ Bug Fixes
|
||||
|
||||
- Fixed a bug which could cause the ``-e/--editable`` argument on a dependency to be accidentally parsed as a dependency itself. `#2714 <https://github.com/pypa/pipenv/issues/2714>`_
|
||||
|
||||
- Correctly pass `verbose` and `debug` flags to the resolver subprocess so it generates appropriate output. This also resolves a bug introduced by the fix to #2527. `#2732 <https://github.com/pypa/pipenv/issues/2732>`_
|
||||
- Correctly pass ``verbose`` and ``debug`` flags to the resolver subprocess so it generates appropriate output. This also resolves a bug introduced by the fix to #2527. `#2732 <https://github.com/pypa/pipenv/issues/2732>`_
|
||||
|
||||
- All markers are now included in ``pipenv lock --requirements`` output. `#2748 <https://github.com/pypa/pipenv/issues/2748>`_
|
||||
|
||||
@@ -273,7 +820,7 @@ Bug Fixes
|
||||
- Fixed a bug in the dependency resolver which caused regular issues when handling ``setup.py`` based dependency resolution. `#2766 <https://github.com/pypa/pipenv/issues/2766>`_
|
||||
|
||||
- Updated vendored dependencies:
|
||||
- ``pip-tools`` (updated and patched to latest w/ ``pip 18.0`` compatibilty)
|
||||
- ``pip-tools`` (updated and patched to latest w/ ``pip 18.0`` compatibility)
|
||||
- ``pip 10.0.1 => 18.0``
|
||||
- ``click 6.7 => 7.0``
|
||||
- ``toml 0.9.4 => 0.10.0``
|
||||
@@ -327,7 +874,7 @@ Vendored Libraries
|
||||
- ``python-dotenv`` to ``0.9.1`` `#2639 <https://github.com/pypa/pipenv/issues/2639>`_
|
||||
|
||||
- Updated vendored dependencies:
|
||||
- ``pip-tools`` (updated and patched to latest w/ ``pip 18.0`` compatibilty)
|
||||
- ``pip-tools`` (updated and patched to latest w/ ``pip 18.0`` compatibility)
|
||||
- ``pip 10.0.1 => 18.0``
|
||||
- ``click 6.7 => 7.0``
|
||||
- ``toml 0.9.4 => 0.10.0``
|
||||
@@ -353,7 +900,7 @@ Improved Documentation
|
||||
|
||||
- Simplified the test configuration process. `#2568 <https://github.com/pypa/pipenv/issues/2568>`_
|
||||
|
||||
- Updated documentation to use working fortune cookie addon. `#2644 <https://github.com/pypa/pipenv/issues/2644>`_
|
||||
- Updated documentation to use working fortune cookie add-on. `#2644 <https://github.com/pypa/pipenv/issues/2644>`_
|
||||
|
||||
- Added additional information about troubleshooting ``pipenv shell`` by using the the ``$PIPENV_SHELL`` environment variable. `#2671 <https://github.com/pypa/pipenv/issues/2671>`_
|
||||
|
||||
@@ -364,7 +911,7 @@ Improved Documentation
|
||||
- Stopped recommending `--system` for Docker contexts. `#2762 <https://github.com/pypa/pipenv/issues/2762>`_
|
||||
|
||||
- Fixed the example url for doing "pipenv install -e
|
||||
some-repo-url#egg=something", it was missing the "egg=" in the fragment
|
||||
some-repository-url#egg=something", it was missing the "egg=" in the fragment
|
||||
identifier. `#2792 <https://github.com/pypa/pipenv/issues/2792>`_
|
||||
|
||||
- Fixed link to the "be cordial" essay in the contribution documentation. `#2793 <https://github.com/pypa/pipenv/issues/2793>`_
|
||||
@@ -382,37 +929,37 @@ Features & Improvements
|
||||
|
||||
- All calls to ``pipenv shell`` are now implemented from the ground up using `shellingham <https://github.com/sarugaku/shellingham>`_, a custom library which was purpose built to handle edge cases and shell detection. `#2371 <https://github.com/pypa/pipenv/issues/2371>`_
|
||||
|
||||
- Added support for python 3.7 via a few small compatibility / bugfixes. `#2427 <https://github.com/pypa/pipenv/issues/2427>`_,
|
||||
- Added support for python 3.7 via a few small compatibility / bug fixes. `#2427 <https://github.com/pypa/pipenv/issues/2427>`_,
|
||||
`#2434 <https://github.com/pypa/pipenv/issues/2434>`_,
|
||||
`#2436 <https://github.com/pypa/pipenv/issues/2436>`_
|
||||
|
||||
- Added new flag ``pipenv --support`` to replace the diagnostic command ``python -m pipenv.help``. `#2477 <https://github.com/pypa/pipenv/issues/2477>`_,
|
||||
`#2478 <https://github.com/pypa/pipenv/issues/2478>`_
|
||||
|
||||
- Improved import times and CLI runtimes with minor tweaks. `#2485 <https://github.com/pypa/pipenv/issues/2485>`_
|
||||
- Improved import times and CLI run times with minor tweaks. `#2485 <https://github.com/pypa/pipenv/issues/2485>`_
|
||||
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Fixed an ongoing bug which sometimes resolved incompatible versions into lockfiles. `#1901 <https://github.com/pypa/pipenv/issues/1901>`_
|
||||
- Fixed an ongoing bug which sometimes resolved incompatible versions into the project Lockfile. `#1901 <https://github.com/pypa/pipenv/issues/1901>`_
|
||||
|
||||
- Fixed a bug which caused errors when creating virtualenvs which contained leading dash characters. `#2415 <https://github.com/pypa/pipenv/issues/2415>`_
|
||||
|
||||
- Fixed a logic error which caused ``--deploy --system`` to overwrite editable vcs packages in the pipfile before installing, which caused any installation to fail by default. `#2417 <https://github.com/pypa/pipenv/issues/2417>`_
|
||||
- Fixed a logic error which caused ``--deploy --system`` to overwrite editable vcs packages in the Pipfile before installing, which caused any installation to fail by default. `#2417 <https://github.com/pypa/pipenv/issues/2417>`_
|
||||
|
||||
- Updated requirementslib to fix an issue with properly quoting markers in VCS requirements. `#2419 <https://github.com/pypa/pipenv/issues/2419>`_
|
||||
|
||||
- Installed new vendored jinja2 templates for ``click-completion`` which were causing template errors for users with completion enabled. `#2422 <https://github.com/pypa/pipenv/issues/2422>`_
|
||||
|
||||
- Added support for python 3.7 via a few small compatibility / bugfixes. `#2427 <https://github.com/pypa/pipenv/issues/2427>`_
|
||||
- Added support for python 3.7 via a few small compatibility / bug fixes. `#2427 <https://github.com/pypa/pipenv/issues/2427>`_
|
||||
|
||||
- Fixed an issue reading package names from ``setup.py`` files in projects which imported utilities such as ``versioneer``. `#2433 <https://github.com/pypa/pipenv/issues/2433>`_
|
||||
|
||||
- Pipenv will now ensure that its internal package names registry files are written with unicode strings. `#2450 <https://github.com/pypa/pipenv/issues/2450>`_
|
||||
|
||||
- Fixed a bug causing requirements input as relative paths to be output as absolute paths or URIs.
|
||||
Fixed a bug affecting normalization of ``git+git@host`` uris. `#2453 <https://github.com/pypa/pipenv/issues/2453>`_
|
||||
Fixed a bug affecting normalization of ``git+git@host`` URLs. `#2453 <https://github.com/pypa/pipenv/issues/2453>`_
|
||||
|
||||
- Pipenv will now always use ``pathlib2`` for ``Path`` based filesystem interactions by default on ``python<3.5``. `#2454 <https://github.com/pypa/pipenv/issues/2454>`_
|
||||
|
||||
@@ -479,7 +1026,7 @@ Features & Improvements
|
||||
patched piptools version. `#2255
|
||||
<https://github.com/pypa/pipenv/issues/2255>`_
|
||||
|
||||
- PyPI mirror URLs can now be set to override instances of PyPI urls by passing
|
||||
- PyPI mirror URLs can now be set to override instances of PyPI URLs by passing
|
||||
the ``--pypi-mirror`` argument from the command line or setting the
|
||||
``PIPENV_PYPI_MIRROR`` environment variable. `#2281
|
||||
<https://github.com/pypa/pipenv/issues/2281>`_
|
||||
@@ -518,7 +1065,7 @@ Behavior Changes
|
||||
|
||||
- Pipenv will now parse & capitalize ``platform_python_implementation`` markers
|
||||
.. warning:: This could cause an issue if you have an out of date ``Pipfile``
|
||||
which lowercases the comparison value (e.g. ``cpython`` instead of
|
||||
which lower-cases the comparison value (e.g. ``cpython`` instead of
|
||||
``CPython``). `#2123 <https://github.com/pypa/pipenv/issues/2123>`_
|
||||
|
||||
- Pipenv will now only search for ``requirements.txt`` files when creating new
|
||||
@@ -572,7 +1119,7 @@ Bug Fixes
|
||||
- Fixed a bug causing pipenv graph to fail to display sometimes. `#2268
|
||||
<https://github.com/pypa/pipenv/issues/2268>`_
|
||||
|
||||
- Updated ``requirementslib`` to fix a bug in pipfile parsing affecting
|
||||
- Updated ``requirementslib`` to fix a bug in Pipfile parsing affecting
|
||||
relative path conversions. `#2269
|
||||
<https://github.com/pypa/pipenv/issues/2269>`_
|
||||
|
||||
@@ -590,11 +1137,11 @@ Bug Fixes
|
||||
requested ref. `#2304 <https://github.com/pypa/pipenv/issues/2304>`_
|
||||
|
||||
- Added error handling functionality to properly cope with single-digit
|
||||
``Requires-Python`` metatdata with no specifiers. `#2377
|
||||
``Requires-Python`` metadata with no specifiers. `#2377
|
||||
<https://github.com/pypa/pipenv/issues/2377>`_
|
||||
|
||||
- ``pipenv update`` will now always run the resolver and lock before ensuring
|
||||
your dependencies are in sync with your lockfile. `#2379
|
||||
dependencies are in sync with project Lockfile. `#2379
|
||||
<https://github.com/pypa/pipenv/issues/2379>`_
|
||||
|
||||
- Resolved a bug in our patched resolvers which could cause nondeterministic
|
||||
@@ -631,7 +1178,7 @@ Vendored Libraries
|
||||
patched piptools version. `#2255
|
||||
<https://github.com/pypa/pipenv/issues/2255>`_
|
||||
|
||||
- Updated ``requirementslib`` to fix a bug in pipfile parsing affecting
|
||||
- Updated ``requirementslib`` to fix a bug in Pipfile parsing affecting
|
||||
relative path conversions. `#2269
|
||||
<https://github.com/pypa/pipenv/issues/2269>`_
|
||||
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
PyPA Projects are governed by the PyPA code of conduct available here:
|
||||
|
||||
https://www.pypa.io/en/latest/code-of-conduct/
|
||||
+1
-251
@@ -1,254 +1,4 @@
|
||||
Contributing to Pipenv
|
||||
======================
|
||||
|
||||
If you\'re reading this, you\'re probably interested in contributing to
|
||||
Pipenv. Thank you very much! Open source projects live-and-die based on
|
||||
the support they receive from others, and the fact that you\'re even
|
||||
considering contributing to the Pipenv project is *very* generous of
|
||||
you.
|
||||
|
||||
This document lays out guidelines and advice for contributing to this
|
||||
project. If you\'re thinking of contributing, please start by reading
|
||||
this document and getting a feel for how contributing to this project
|
||||
works. If you have any questions, feel free to reach out to either [Dan
|
||||
Ryan](https://github.com/techalchemy), [Tzu-ping
|
||||
Chung](https://github.com/uranusjr), or [Nate
|
||||
Prewitt](https://github.com/nateprewitt), the primary maintainers.
|
||||
|
||||
The guide is split into sections based on the type of contribution
|
||||
you\'re thinking of making, with a section that covers general
|
||||
guidelines for all contributors.
|
||||
|
||||
General Guidelines
|
||||
------------------
|
||||
|
||||
### Be Cordial
|
||||
|
||||
> **Be cordial or be on your way**. *---Kenneth Reitz*
|
||||
|
||||
Pipenv has one very important rule governing all forms of contribution,
|
||||
including reporting bugs or requesting features. This golden rule is
|
||||
\"[be cordial or be on your
|
||||
way](https://www.kennethreitz.org/essays/be-cordial-or-be-on-your-way)\".
|
||||
|
||||
**All contributions are welcome**, as long as everyone involved is
|
||||
treated with respect.
|
||||
|
||||
### Get Early Feedback {#early-feedback}
|
||||
|
||||
If you are contributing, do not feel the need to sit on your
|
||||
contribution until it is perfectly polished and complete. It helps
|
||||
everyone involved for you to seek feedback as early as you possibly can.
|
||||
Submitting an early, unfinished version of your contribution for
|
||||
feedback in no way prejudices your chances of getting that contribution
|
||||
accepted, and can save you from putting a lot of work into a
|
||||
contribution that is not suitable for the project.
|
||||
|
||||
### Contribution Suitability
|
||||
|
||||
Our project maintainers have the last word on whether or not a
|
||||
contribution is suitable for Pipenv. All contributions will be
|
||||
considered carefully, but from time to time, contributions will be
|
||||
rejected because they do not suit the current goals or needs of the
|
||||
project.
|
||||
|
||||
If your contribution is rejected, don\'t despair! As long as you
|
||||
followed these guidelines, you will have a much better chance of getting
|
||||
your next contribution accepted.
|
||||
|
||||
Questions
|
||||
---------
|
||||
|
||||
The GitHub issue tracker is for *bug reports* and *feature requests*.
|
||||
Please do not use it to ask questions about how to use Pipenv. These
|
||||
questions should instead be directed to [Stack
|
||||
Overflow](https://stackoverflow.com/). Make sure that your question is
|
||||
tagged with the `pipenv` tag when asking it on Stack Overflow, to ensure
|
||||
that it is answered promptly and accurately.
|
||||
|
||||
Code Contributions
|
||||
------------------
|
||||
|
||||
### Steps for Submitting Code
|
||||
|
||||
When contributing code, you\'ll want to follow this checklist:
|
||||
|
||||
1. Understand our [development
|
||||
philosophy](https://docs.pipenv.org/dev/philosophy/).
|
||||
2. Fork the repository on GitHub.
|
||||
3. Set up your `dev-setup`{.interpreted-text role="ref"}
|
||||
4. Run the tests (`testing`{.interpreted-text role="ref"}) to confirm
|
||||
they all pass on your system. If they don\'t, you\'ll need to
|
||||
investigate why they fail. If you\'re unable to diagnose this
|
||||
yourself, raise it as a bug report by following the guidelines in
|
||||
this document: `bug-reports`{.interpreted-text role="ref"}.
|
||||
5. Write tests that demonstrate your bug or feature. Ensure that they
|
||||
fail.
|
||||
6. Make your change.
|
||||
7. Run the entire test suite again, confirming that all tests pass
|
||||
*including the ones you just added*.
|
||||
8. Send a GitHub Pull Request to the main repository\'s `master`
|
||||
branch. GitHub Pull Requests are the expected method of code
|
||||
collaboration on this project.
|
||||
|
||||
The following sub-sections go into more detail on some of the points
|
||||
above.
|
||||
|
||||
### Development Setup {#dev-setup}
|
||||
|
||||
To get your development environment setup, run:
|
||||
|
||||
``` {.sh}
|
||||
pip install -e .
|
||||
pipenv install --dev
|
||||
```
|
||||
|
||||
This will install the repo version of Pipenv and then install the
|
||||
development dependencies. Once that has completed, you can start
|
||||
developing.
|
||||
|
||||
The repo version of Pipenv must be installed over other global versions
|
||||
to resolve conflicts with the `pipenv` folder being implicitly added to
|
||||
`sys.path`. See
|
||||
[pypa/pipenv\#2557](https://github.com/pypa/pipenv/issues/2557) for more
|
||||
details.
|
||||
|
||||
### Testing
|
||||
|
||||
Tests are written in `pytest` style and can be run very simply:
|
||||
|
||||
``` {.sh}
|
||||
pytest
|
||||
```
|
||||
|
||||
This will run all Pipenv tests, which can take awhile. To run a subset
|
||||
of the tests, the standard pytest filters are available, such as:
|
||||
|
||||
- provide a directory or file: `pytest tests/unit` or
|
||||
`pytest tests/unit/test_cmdparse.py`
|
||||
- provide a keyword expression:
|
||||
`pytest -k test_lock_editable_vcs_without_install`
|
||||
- provide a nodeid: `pytest tests/unit/test_cmdparse.py::test_parse`
|
||||
- provide a test marker: `pytest -m lock`
|
||||
|
||||
### Code Review
|
||||
|
||||
Contributions will not be merged until they\'ve been code reviewed. You
|
||||
should implement any code review feedback unless you strongly object to
|
||||
it. In the event that you object to the code review feedback, you should
|
||||
make your case clearly and calmly. If, after doing so, the feedback is
|
||||
judged to still apply, you must either apply the feedback or withdraw
|
||||
your contribution.
|
||||
|
||||
### Package Index
|
||||
|
||||
To speed up testing, tests that rely on a package index for locking and
|
||||
installing use a local server that contains vendored packages in the
|
||||
`tests/pypi` directory. Each vendored package should have it\'s own
|
||||
folder containing the necessary releases. When adding a release for a
|
||||
package, it is easiest to use either the `.tar.gz` or universal wheels
|
||||
(ex: `py2.py3-none`). If a `.tar.gz` or universal wheel is not
|
||||
available, add wheels for all available architectures and platforms.
|
||||
|
||||
Documentation Contributions
|
||||
---------------------------
|
||||
|
||||
Documentation improvements are always welcome! The documentation files
|
||||
live in the `docs/` directory of the codebase. They\'re written in
|
||||
[reStructuredText](http://docutils.sourceforge.net/rst.html), and use
|
||||
[Sphinx](http://sphinx-doc.org/index.html) to generate the full suite of
|
||||
documentation.
|
||||
|
||||
When contributing documentation, please do your best to follow the style
|
||||
of the documentation files. This means a soft-limit of 79 characters
|
||||
wide in your text files and a semi-formal, yet friendly and
|
||||
approachable, prose style.
|
||||
|
||||
When presenting Python code, use single-quoted strings (`'hello'`
|
||||
instead of `"hello"`).
|
||||
|
||||
Bug Reports
|
||||
-----------
|
||||
|
||||
Bug reports are hugely important! They are recorded as [GitHub
|
||||
issues](https://github.com/pypa/pipenv/issues). Please be aware of the
|
||||
following things when filing bug reports:
|
||||
|
||||
1. Avoid raising duplicate issues. *Please* use the GitHub issue search
|
||||
feature to check whether your bug report or feature request has been
|
||||
mentioned in the past. Duplicate bug reports and feature requests
|
||||
are a huge maintenance burden on the limited resources of the
|
||||
project. If it is clear from your report that you would have
|
||||
struggled to find the original, that\'s ok, but if searching for a
|
||||
selection of words in your issue title would have found the
|
||||
duplicate then the issue will likely be closed extremely abruptly.
|
||||
|
||||
2. When filing bug reports about exceptions or tracebacks, please
|
||||
include the *complete* traceback. Partial tracebacks, or just the
|
||||
exception text, are not helpful. Issues that do not contain complete
|
||||
tracebacks may be closed without warning.
|
||||
|
||||
3. Make sure you provide a suitable amount of information to work with.
|
||||
This means you should provide:
|
||||
|
||||
- Guidance on **how to reproduce the issue**. Ideally, this should
|
||||
be a *small* code sample that can be run immediately by the
|
||||
maintainers. Failing that, let us know what you\'re doing, how
|
||||
often it happens, what environment you\'re using, etc. Be
|
||||
thorough: it prevents us needing to ask further questions.
|
||||
- Tell us **what you expected to happen**. When we run your
|
||||
example code, what are we expecting to happen? What does
|
||||
\"success\" look like for your code?
|
||||
- Tell us **what actually happens**. It\'s not helpful for you to
|
||||
say \"it doesn\'t work\" or \"it fails\". Tell us *how* it
|
||||
fails: do you get an exception? A hang? The packages installed
|
||||
seem incorrect? How was the actual result different from your
|
||||
expected result?
|
||||
- Tell us **what version of Pipenv you\'re using**, and **how you
|
||||
installed it**. Different versions of Pipenv behave differently
|
||||
and have different bugs, and some distributors of Pipenv ship
|
||||
patches on top of the code we supply.
|
||||
|
||||
If you do not provide all of these things, it will take us much
|
||||
longer to fix your problem. If we ask you to clarify these and you
|
||||
never respond, we will close your issue without fixing it.
|
||||
|
||||
Run the tests
|
||||
-------------
|
||||
|
||||
Three ways of running the tests are as follows:
|
||||
|
||||
1. `make test` (which uses `docker`)
|
||||
2. `./run-tests.sh` or `run-tests.bat`
|
||||
3. Using pipenv:
|
||||
|
||||
``` {.console}
|
||||
$ git clone https://github.com/pypa/pipenv.git
|
||||
$ cd pipenv
|
||||
$ git submodule sync && git submodule update --init --recursive
|
||||
$ pipenv install --dev
|
||||
$ pipenv run pytest
|
||||
```
|
||||
|
||||
For the last two, it is important that your environment is setup
|
||||
correctly, and this may take some work, for example, on a specific Mac
|
||||
installation, the following steps may be needed:
|
||||
|
||||
# Make sure the tests can access github
|
||||
if [ "$SSH_AGENT_PID" = "" ]
|
||||
then
|
||||
eval `ssh-agent`
|
||||
ssh-add
|
||||
fi
|
||||
|
||||
# Use unix like utilities, installed with brew,
|
||||
# e.g. brew install coreutils
|
||||
for d in /usr/local/opt/*/libexec/gnubin /usr/local/opt/python/libexec/bin
|
||||
do
|
||||
[[ ":$PATH:" != *":$d:"* ]] && PATH="$d:${PATH}"
|
||||
done
|
||||
|
||||
export PATH
|
||||
|
||||
# PIP_FIND_LINKS currently breaks test_uninstall.py
|
||||
unset PIP_FIND_LINKS
|
||||
Please see: [docs/dev/contributing.rst](https://pipenv.pypa.io/en/latest/dev/contributing/).
|
||||
|
||||
-39
@@ -1,39 +0,0 @@
|
||||
FROM heroku/heroku:18-build
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
ENV LC_ALL C.UTF-8
|
||||
ENV LANG C.UTF-8
|
||||
# Python, don't write bytecode!
|
||||
ENV PYTHONDONTWRITEBYTECODE 1
|
||||
|
||||
# -- Install Pipenv:
|
||||
RUN apt update && apt install python3.7-dev libffi-dev -y
|
||||
RUN curl --silent https://bootstrap.pypa.io/get-pip.py | python3.7
|
||||
|
||||
# Backwards compatility.
|
||||
RUN rm -fr /usr/bin/python3 && ln /usr/bin/python3.7 /usr/bin/python3
|
||||
|
||||
RUN pip3 install pipenv
|
||||
|
||||
# -- Install Application into container:
|
||||
RUN set -ex && mkdir /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# -- Adding Pipfiles
|
||||
ONBUILD COPY Pipfile Pipfile
|
||||
ONBUILD COPY Pipfile.lock Pipfile.lock
|
||||
|
||||
# -- Install dependencies:
|
||||
ONBUILD RUN set -ex && pipenv install --deploy --system
|
||||
|
||||
# --------------------
|
||||
# - Using This File: -
|
||||
# --------------------
|
||||
|
||||
# FROM kennethreitz/pipenv
|
||||
|
||||
# COPY . /app
|
||||
|
||||
# -- Replace with the correct path to your app's main executable
|
||||
# CMD python3 main.py
|
||||
+11
-6
@@ -1,24 +1,28 @@
|
||||
include LICENSE README.md CONTRIBUTING.md CODE_OF_CONDUCT.md CHANGELOG.rst NOTICES HISTORY.txt
|
||||
include Makefile pyproject.toml get-pipenv.py
|
||||
include LICENSE README.md CONTRIBUTING.md CHANGELOG.rst NOTICES HISTORY.txt
|
||||
include Makefile pyproject.toml get-pipenv.py *.yml
|
||||
include examples/Pipfil*
|
||||
include *.md
|
||||
|
||||
recursive-include pipenv LICENSE LICENSE* *LICENSE* *COPYING* t32.exe t64.exe w32.exe w64.exe cacert.pem
|
||||
recursive-include pipenv *.cfg
|
||||
recursive-include pipenv/vendor *.c *.j2
|
||||
recursive-include pipenv/vendor *.c
|
||||
recursive-include pipenv *.md *.APACHE *.BSD
|
||||
recursive-include pipenv Makefile
|
||||
recursive-include pipenv/vendor vendor.txt
|
||||
recursive-include pipenv README
|
||||
recursive-include pipenv *.json
|
||||
recursive-include pipenv *.rst
|
||||
|
||||
include pipenv/patched/notpip/_vendor/vendor.txt
|
||||
include pipenv/patched/safety.zip pipenv/patched/patched.txt
|
||||
include pipenv/vendor/pipreqs/stdlib pipenv/vendor/pipreqs/mapping
|
||||
include pipenv/vendor/*.txt pipenv/vendor/pexpect/bashrc.sh
|
||||
include pipenv/vendor/Makefile
|
||||
include pipenv/pipenv.1
|
||||
|
||||
exclude .gitmodules
|
||||
exclude .editorconfig .travis.yml .env appveyor.yml tox.ini pytest.ini
|
||||
exclude Pipfile* CHANGELOG.draft.rst
|
||||
exclude docker-compose.yml Dockerfile
|
||||
exclude run-tests.sh run-tests.bat
|
||||
|
||||
recursive-include docs Makefile *.rst *.py *.bat
|
||||
@@ -27,13 +31,14 @@ recursive-include docs/_static *.js *.css *.png
|
||||
recursive-exclude docs requirements*.txt
|
||||
recursive-exclude pipenv *.pyi
|
||||
recursive-exclude pipenv *.typed
|
||||
recursive-exclue tests/test_artifacts *.pyd *.so *.pyc *.egg-info PKG-INFO
|
||||
|
||||
prune peeps
|
||||
prune .azure-pipelines
|
||||
prune .buildkite
|
||||
prune .github
|
||||
prune .vsts-ci
|
||||
prune docs/build
|
||||
prune news
|
||||
prune tasks
|
||||
prune tests
|
||||
prune pipenv/vendor/importlib_metadata/tests
|
||||
prune pipenv/vendor/importlib_resources/tests
|
||||
|
||||
@@ -2,11 +2,42 @@ get_venv_dir:=$(shell mktemp -d 2>/dev/null || mktemp -d -t 'tmpvenv')
|
||||
venv_dir := $(get_venv_dir)/pipenv_venv
|
||||
venv_file := $(CURDIR)/.test_venv
|
||||
get_venv_path =$(file < $(venv_file))
|
||||
# This is how we will build tag-specific wheels, e.g. py36 or py37
|
||||
PY_VERSIONS:= 2.7 3.5 3.6 3.7 3.8
|
||||
BACKSLASH = '\\'
|
||||
# This is how we will build generic wheels, e.g. py2 or py3
|
||||
INSTALL_TARGETS := $(addprefix install-py,$(PY_VERSIONS))
|
||||
CLEAN_TARGETS := $(addprefix clean-py,$(PY_VERSIONS))
|
||||
DATE_STRING := $(shell date +%Y.%m.%d)
|
||||
THIS_MONTH_DATE := $(shell date +%Y.%m.01)
|
||||
NEXT_MONTH_DATE := $(shell date -d "+1 month" +%Y.%m.01)
|
||||
PATCHED_PIP_VERSION := $(shell awk '/__version__/{gsub(/"/,"",$$3); print $$3}' pipenv/patched/notpip/__init__.py)
|
||||
PATCHED_PIPTOOLS_VERSION := $(shell awk -F "=" '/pip-tools/ {print $$3}' pipenv/patched/patched.txt)
|
||||
GITDIR_STAMPFILE := $(CURDIR)/.git-checkout-dir
|
||||
create_git_tmpdir = $(shell mktemp -dt pipenv-vendor-XXXXXXXX 2>/dev/null || mktemp -d 2>/dev/null)
|
||||
write_git_tmpdir = $(file > $(GITDIR_STAMPFILE),$(create_git_tmpdir))
|
||||
get_checkout_dir = $(file < $(GITDIR_STAMPFILE))
|
||||
get_checkout_subdir = $(addprefix $(get_checkout_dir), $(1))
|
||||
pip-checkout-dir = $(get_checkout_dir)/patch-pip
|
||||
piptools-checkout-dir = $(get_checkout_dir)/patch-piptools
|
||||
|
||||
format:
|
||||
black pipenv/*.py
|
||||
test:
|
||||
docker-compose up
|
||||
|
||||
.PHONY: install
|
||||
install:
|
||||
pip install -e .
|
||||
|
||||
install.stamp: install
|
||||
@touch install.stamp
|
||||
|
||||
.PHONY: install-py%
|
||||
install-py%: install.stamp
|
||||
@echo building for $(addprefix python, $(subst install-py,,$@))
|
||||
PIPENV_PYTHON=$(subst install-py,,$@) pipenv install --dev
|
||||
|
||||
install-virtualenvs.stamp: ${INSTALL_TARGETS}
|
||||
@touch install-virtualenvs.stamp
|
||||
|
||||
.PHONY: ramdisk
|
||||
ramdisk:
|
||||
@@ -48,3 +79,100 @@ test-specific: submodules virtualenv test-install
|
||||
.PHONY: retest
|
||||
retest: virtualenv submodules test-install
|
||||
. $(get_venv_path)/bin/activate && pipenv run pytest -ra -k 'test_check_unused or test_install_editable_git_tag or test_get_vcs_refs or test_skip_requirements_when_pipfile or test_editable_vcs_install or test_basic_vcs_install or test_git_vcs_install or test_ssh_vcs_install or test_vcs_can_use_markers' -vvv --full-trace --tb=long
|
||||
|
||||
.PHONY: build
|
||||
build: install-virtualenvs.stamp install.stamp
|
||||
PIPENV_PYTHON=3.7 pipenv run python setup.py sdist bdist_wheel
|
||||
|
||||
.PHONY: update-version
|
||||
update-version:
|
||||
@sed -i "s/^__version__ = .\+$\/__version__ = \"$(DATE_STRING)\"/g" ./pipenv/__version__.py
|
||||
|
||||
.PHONY: update-prerelease-version
|
||||
update-prerelease-version:
|
||||
@sed -i "s/^__version__ = .\+$\/__version__ = \"$(THIS_MONTH_DATE).a1\"/g" ./pipenv/__version__.py
|
||||
|
||||
.PHONY: pre-bump
|
||||
pre-bump:
|
||||
@sed -i "s/^__version__ = .\+$\/__version__ = \"$(NEXT_MONTH_DATE).dev0\"/g" ./pipenv/__version__.py
|
||||
|
||||
.PHONY: lint
|
||||
lint:
|
||||
flake8 .
|
||||
|
||||
man:
|
||||
$(MAKE) -C docs $@
|
||||
|
||||
.PHONY: check
|
||||
check: build.stamp
|
||||
pipenv run twine check dist/* && pipenv run check-manifest .
|
||||
|
||||
.PHONY: upload-test
|
||||
upload-test: build
|
||||
twine upload --repository=testpypi dist/*
|
||||
|
||||
.PHONY: clean-py%
|
||||
clean-py%:
|
||||
@echo "cleaning environment for $@..."
|
||||
PIPENV_PYTHON="$(subst clean-py,,$@)" pipenv --rm
|
||||
|
||||
.PHONY: cleanbuild
|
||||
cleanbuild:
|
||||
@echo "cleaning up existing builds..."
|
||||
@rm -rf build/ dist/
|
||||
@rm -rf build.stamp
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -rf install.stamp build.stamp install-virtualenvs.stamp .git-checkout-dir
|
||||
|
||||
.PHONY: gitclean
|
||||
gitclean:
|
||||
@echo "Cleaning up git trees..."
|
||||
@rm -rf $(file < .git-checkout-dir)
|
||||
@echo "Cleaning up git checkout stamp"
|
||||
@rm -rf .git-checkout-dir
|
||||
|
||||
.git-checkout-dir:
|
||||
@echo "Creating git repo temp file"
|
||||
@echo "Creating git checkout stamp file at .git-checkout-dir"
|
||||
@echo $(file > $(CURDIR)/.git-checkout-dir,$(shell mktemp -dt pipenv-vendor-XXXXXXXX 2>/dev/null || mktemp -d 2>/dev/null))
|
||||
|
||||
.PHONY: clone-pip
|
||||
clone-pip: .git-checkout-dir
|
||||
[ -e $(pip-checkout-dir) ] && echo "Pip already exists, moving on!" || git clone https://github.com/pypa/pip.git $(pip-checkout-dir) -b $(PATCHED_PIP_VERSION)
|
||||
|
||||
.PHONY: clone-piptools
|
||||
clone-piptools: .git-checkout-dir
|
||||
[ -e $(piptools-checkout-dir) ] && echo "Piptools already exists, moving on!" || git clone https://github.com/jazzband/pip-tools.git $(piptools-checkout-dir) -b $(PATCHED_PIPTOOLS_VERSION)
|
||||
|
||||
.PHONY: patch-pip
|
||||
patch-pip: clone-pip
|
||||
@find $(CURDIR)/tasks/vendoring/patches/patched/ -regex ".*/pip[0-9]+.patch" -exec cp {} $(pip-checkout-dir) \;
|
||||
@sed -i -r 's:([a-b]\/)pipenv/patched/:\1src/:g' $(pip-checkout-dir)/*.patch
|
||||
@find $(CURDIR)/tasks/vendoring/patches/patched/ -regex ".*/_post-pip-[^/\.]*.patch" -exec cp {} $(pip-checkout-dir)/ \;
|
||||
@sed -i -r 's:([a-b]\/)pipenv/patched/not:\1src/:g' $(pip-checkout-dir)/_post-*.patch
|
||||
@cd $(pip-checkout-dir)/ && git apply --ignore-whitespace --verbose pip*.patch
|
||||
@echo "Head to $(pip-checkout-dir) to update the pip patches to the latest version"
|
||||
|
||||
.PHONY: patch-piptools
|
||||
patch-piptools: clone-piptools
|
||||
@find $(CURDIR)/tasks/vendoring/patches/patched/ -regex ".*/piptools[^/\.]*.patch" -exec cp {} $(piptools-checkout-dir)/ \;
|
||||
@sed -i -r 's:([a-b]\/)pipenv/patched/:\1/:g' $(piptools-checkout-dir)/*.patch
|
||||
@cd $(piptools-checkout-dir)/ && git apply --ignore-whitespace --verbose piptools*.patch
|
||||
@echo "Head to $(piptools-checkout-dir) to update the piptools patches to the latest version"
|
||||
|
||||
.PHONY: patches
|
||||
patches: patch-pip patch-piptools
|
||||
|
||||
.PHONY: reimport-pip-patch
|
||||
reimport-pip-patch:
|
||||
@sed -i -r 's:([a-b]\/)src/:\1pipenv/patched/not:g' $(pip-checkout-dir)/_post-*.patch
|
||||
@sed -i -r 's:([a-b]\/)src/:\1pipenv/patched/:g' $(pip-checkout-dir)/pip*.patch
|
||||
@find $(pip-checkout-dir) -maxdepth 1 -regex ".*/pip[0-9]+.patch" -exec cp {} $(CURDIR)/tasks/vendoring/patches/patched/ \;
|
||||
@find $(pip-checkout-dir) -maxdepth 1 -regex ".*/_post-pip-[^/\.]*.patch" -exec cp {} $(CURDIR)/tasks/vendoring/patches/patched/ \;
|
||||
|
||||
.PHONY: reimport-piptools-patch
|
||||
reimport-piptools-patch:
|
||||
@sed -i -r 's:([a-b]\/):\1pipenv/patched/:g' $(piptools-checkout-dir)/*.patch
|
||||
@find $(piptools-checkout-dir)/ -maxdepth 1 -regex ".*/piptools[^/\.]*.patch" -exec cp {} $(CURDIR)/tasks/vendoring/patches/patched/ \;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
The contents of the vendor and patched directories are subject to different licenses
|
||||
than the rest of this project.
|
||||
than the rest of this project.
|
||||
|
||||
Their respective licenses can be looked up at pypi.python.org or in their
|
||||
Their respective licenses can be looked up at pypi.python.org or in their
|
||||
corresponding LICENSE files.
|
||||
|
||||
@@ -1,13 +1,11 @@
|
||||
[dev-packages]
|
||||
pipenv = {path = ".", editable = true, extras = ["tests", "dev"]}
|
||||
sphinx-click = "*"
|
||||
sphinx-click = "<3"
|
||||
click = "*"
|
||||
pytest_pypi = {path = "./tests/pytest-pypi", editable = true}
|
||||
stdeb = {version="*", markers="sys_platform == 'linux'"}
|
||||
jedi = "*"
|
||||
isort = "*"
|
||||
rope = "*"
|
||||
passa = {git = "https://github.com/sarugaku/passa.git"}
|
||||
dataclasses = {version="*", markers="python_version < '3.7'"}
|
||||
sphinxcontrib-spelling = "<4.3.0"
|
||||
|
||||
[packages]
|
||||
|
||||
|
||||
Generated
+526
-430
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,7 @@ Pipenv: Python Development Workflow for Humans
|
||||
|
||||
[](https://python.org/pypi/pipenv)
|
||||
[](https://python.org/pypi/pipenv)
|
||||
[](https://dev.azure.com/pypa/pipenv/_build/latest?definitionId=16&branchName=master)
|
||||
[](https://github.com/pypa/pipenv/actions/workflows/ci.yaml)
|
||||
[](https://python.org/pypi/pipenv)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
@@ -24,7 +24,7 @@ The problems that Pipenv seeks to solve are multi-faceted:
|
||||
- You no longer need to use `pip` and `virtualenv` separately. They
|
||||
work together.
|
||||
- Managing a `requirements.txt` file [can be
|
||||
problematic](https://www.kennethreitz.org/essays/a-better-pip-workflow),
|
||||
problematic](https://kennethreitz.org/essays/2016/02/25/a-better-pip-workflow),
|
||||
so Pipenv uses the upcoming `Pipfile` and `Pipfile.lock` instead,
|
||||
which is superior for basic use cases.
|
||||
- Hashes are used everywhere, always. Security. Automatically expose
|
||||
@@ -39,21 +39,27 @@ You can quickly play with Pipenv right in your browser:
|
||||
Installation
|
||||
------------
|
||||
|
||||
If you\'re on MacOS, you can install Pipenv easily with Homebrew:
|
||||
**Pipenv can be installed with Python 3.6 and above.**
|
||||
|
||||
$ brew install pipenv
|
||||
If you\'re using Debian Buster+:
|
||||
|
||||
Or, if you\'re using Debian Buster+:
|
||||
|
||||
$ sudo apt install pipenv
|
||||
sudo apt install pipenv
|
||||
|
||||
Or, if you\'re using Fedora:
|
||||
|
||||
$ sudo dnf install pipenv
|
||||
|
||||
sudo dnf install pipenv
|
||||
|
||||
Or, if you\'re using FreeBSD:
|
||||
|
||||
# pkg install py36-pipenv
|
||||
pkg install py36-pipenv
|
||||
|
||||
Or, if you\'re using Windows:
|
||||
|
||||
pip install --user pipenv
|
||||
|
||||
When none of the above is an option, it is recommended to use [Pipx](https://pypi.org/p/pipx):
|
||||
|
||||
pipx install pipenv
|
||||
|
||||
Otherwise, refer to the [documentation](https://pipenv.pypa.io/en/latest/#install-pipenv-today) for instructions.
|
||||
|
||||
@@ -117,20 +123,22 @@ activate a virtualenv, run `$ pipenv shell`).
|
||||
|
||||
### Shell Completion
|
||||
|
||||
For example, with fish, put this in your
|
||||
`~/.config/fish/completions/pipenv.fish`:
|
||||
To enable completion in fish, add this to your configuration `~/.config/fish/completions/pipenv.fish`:
|
||||
|
||||
eval (pipenv --completion)
|
||||
eval (env _PIPENV_COMPLETE=fish_source pipenv)
|
||||
|
||||
Alternatively, with bash, put this in your `.bashrc` or `.bash_profile`:
|
||||
|
||||
eval "$(pipenv --completion)"
|
||||
|
||||
Magic shell completions are now enabled! There is also a [fish
|
||||
plugin](https://github.com/fisherman/pipenv), which will automatically
|
||||
There is also a [fish plugin](https://github.com/fisherman/pipenv), which will automatically
|
||||
activate your subshells for you!
|
||||
|
||||
Fish is the best shell. You should use it.
|
||||
Alternatively, with zsh, add this to your configuration `~/.zshrc`:
|
||||
|
||||
eval "$(_PIPENV_COMPLETE=zsh_source pipenv)"
|
||||
|
||||
Alternatively, with bash, add this to your configuration `~/.bashrc` or `~/.bash_profile`:
|
||||
|
||||
eval "$(_PIPENV_COMPLETE=bash_source pipenv)"
|
||||
|
||||
Magic shell completions are now enabled!
|
||||
|
||||
☤ Usage
|
||||
-------
|
||||
@@ -145,7 +153,6 @@ Fish is the best shell. You should use it.
|
||||
--envs Output Environment Variable options.
|
||||
--rm Remove the virtualenv.
|
||||
--bare Minimal output.
|
||||
--completion Output completion (to be eval'd).
|
||||
--man Display manpage.
|
||||
--three / --two Use Python 3/2 when creating virtualenv.
|
||||
--python TEXT Specify which version of Python virtualenv should use.
|
||||
@@ -189,6 +196,8 @@ Fish is the best shell. You should use it.
|
||||
lock Generates Pipfile.lock.
|
||||
open View a given module in your editor.
|
||||
run Spawns a command installed into the virtualenv.
|
||||
scripts Displays the shortcuts in the (optional) [scripts] section of
|
||||
Pipfile.
|
||||
shell Spawns a shell within the virtualenv.
|
||||
sync Installs all packages specified in Pipfile.lock.
|
||||
uninstall Un-installs a provided package and removes it from Pipfile.
|
||||
@@ -289,7 +298,7 @@ Uninstall everything:
|
||||
Use the shell:
|
||||
|
||||
$ pipenv shell
|
||||
Loading .env environment variables…
|
||||
Loading .env environment variables...
|
||||
Launching subshell in virtual environment. Type 'exit' or 'Ctrl+D' to return.
|
||||
$ ▯
|
||||
|
||||
|
||||
+172
@@ -0,0 +1,172 @@
|
||||
# Releasing Pipenv
|
||||
|
||||
We recognize that the pipenv release process is currently poorly managed. That's why this document seeks to streamline the release process, identify current complexities, and help eliminate existing single points of failure.
|
||||
|
||||
## Development Install
|
||||
|
||||
Any new release will require you to have the latest version of master installed in development mode:
|
||||
|
||||
```bash
|
||||
$ git checkout master
|
||||
$ git fetch origin
|
||||
$ git pull
|
||||
$ pipenv install --dev
|
||||
```
|
||||
|
||||
## Make new releases of related libraries
|
||||
|
||||
A lot of pipenv depends on ancillary libraries. You may need to make new releases of:
|
||||
|
||||
* [requirementslib](https://pypi.org/project/requirementslib/)
|
||||
* [pip-shims](https://pypi.org/project/pip-shims/)
|
||||
* [vistir](https://pypi.org/project/vistir/)
|
||||
* [pythonfinder](https://pypi.org/project/pythonfinder/)
|
||||
|
||||
## Updating Vendored Dependencies
|
||||
|
||||
This is the most complex element of releasing new versions of pipenv due to existing patches on current code. Currently the largest patchsets are maintained against [pip](https://github.com/pypa/pip) and [pip-tools](https://github.com/jazzband/pip-tools).
|
||||
|
||||
You can begin by reviewing vendored dependencies which can be found in `pipenv/vendor/vendor.txt`, a file which is consumed by the automated vendoring process. These dependencies may have minor patches applied which can be found in `tasks/vendoring/patches/vendor`. Check PyPI for updates to the specified packages and increment the versions as needed, making sure to capture all dependencies in case any were added. It would be *very bad* to release without necessary dependencies, obviously.
|
||||
|
||||
Next you can consult `pipenv/patched/patched.txt` which enumerates the patched dependencies. Follow the same process, but be aware that you will need to rewrite patches for each dependency once you update (most likely) as they do tend to change somewhat substantially.
|
||||
|
||||
|
||||
### Update Safety
|
||||
|
||||
Pipenv also includes a vendored copy of `safety` for checking for vulnerabilities against the `pyup.io` database. In order to update the `safety` package, run the following:
|
||||
|
||||
```console
|
||||
$ inv vendoring.update-safety
|
||||
```
|
||||
|
||||
|
||||
### Updating patches
|
||||
|
||||
For larger libraries you can keep local clones of them and simply generate full patch sets in which you replace the updated path in pipenv when you are done making changes. Here is an example of a script used from inside a local clone of `pip` to generate a patch and copy it to pipenv's local patches directory.
|
||||
|
||||
```bash
|
||||
#!/usr/bin/bash
|
||||
sed -i -r 's/([a-b]\/)(?:src\/)?(pip)/\1pipenv\/patched\/\2/g' diff.patch
|
||||
cp diff.patch ../pipenv/tasks/vendoring/patches/patched/pip19.patch
|
||||
```
|
||||
|
||||
Assuming patches are kept up to date and you are simply working on a modification that is relatively minor, here is a script you can use to pull in a single modified file from `pipenv` into a local clone of `pip-tools` and regenerate a patch from the updated version of that file:
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
cp ../pipenv/pipenv/patched/piptools/$@ piptools/$@
|
||||
sed -i 's/pipenv.patched.notpip/pip/g' piptools/$@
|
||||
git diff -p piptools/$@ > diff.patch
|
||||
sed -i -r 's:([a-b]/)(piptools):\1pipenv/patched/\2:g' diff.patch
|
||||
```
|
||||
|
||||
The resulting patch is then combined into the patchset by hand (make sure you don't alter the whitespace in the patch!)
|
||||
|
||||
|
||||
## Updating Vendored Dependencies (continued)
|
||||
|
||||
Okay, now that's done, it's time to update vendored dependencies. You can install pipenv itself by moving to the source directory (`cd pipenv`) and running `pip install -e .`. Then you can run `pipenv install --dev` to install the development dependencies into a virtual environment.
|
||||
|
||||
Update the vendored dependencies by copying the `pipenv/vendor/vendor.txt` file to a new directory (e.g. `/tmp/vendor`) and unpinning all of the dependencies. Note there is a helper script for this:
|
||||
|
||||
```bash
|
||||
$ pipenv run inv vendoring.unpin-and-update-vendored
|
||||
```
|
||||
|
||||
This should unpin all vendored and patched dependencies and resolve them; ideally you would keep the file formatted so that we can see what depends on what, but this will tell you what can be updated & provide the latest versions.
|
||||
|
||||
To re-vendor and patch the vendored libraries, run the command:
|
||||
|
||||
```bash
|
||||
$ pipenv run inv vendoring.update
|
||||
```
|
||||
|
||||
This will automatically remove the `./pipenv/vendor/` and `./pipenv/patched/` directories and re-download and patch the specified dependencies. It will also attempt to download any relevant licenses. Once this is completed, run `git status` and inspect the output -- look through the `git diff` for anything that may cause breakages. If any licenses have been deleted, you will need to determine why they were not replaced by the license download tooling.
|
||||
|
||||
## Review Vendored Licenses
|
||||
|
||||
|
||||
Make sure to read through any modified license files for changes -- note that we cannot redistribute code that is licensed under a [copyleft](https://en.wikipedia.org/wiki/Copyleft) license, such as the [GPL](https://en.wikipedia.org/wiki/GPL). Similarly, all vendored code **must** be licensed or it cannot be redistributed. If vendored libraries have become unlicensed or are no longer usable, suitable replacements will have to be found and potentially patched into the vendored dependencies. This may be a good time to consider simply including the dependency as an install requirement.
|
||||
|
||||
### TODO
|
||||
Look into using a tool like https://fossa.com/ to help with this.
|
||||
|
||||
|
||||
## Update Pipfile.lock
|
||||
|
||||
Now we will need to update the lockfile. This is required to ensure tests run against the latest versions of libraries. You will need to run the following:
|
||||
|
||||
```bash
|
||||
# use the latest python here
|
||||
$ export PIPENV_PYTHON=3.8
|
||||
$ pipenv lock --dev
|
||||
# Inspect the changes in a diff viewer, for example we should keep the python 2 dependencies to use for running tests
|
||||
# on completion, stage the relevant changes
|
||||
$ export PIPENV_PYTHON=2.7
|
||||
$ pipenv lock --keep-outdated --dev
|
||||
# this helps avoid overwriting the entire lockfile and should introduce only the changes required to run tests on python 2
|
||||
# inspect the resulting lockfile and commit the changes
|
||||
$ git commit
|
||||
```
|
||||
|
||||
## Test locally
|
||||
|
||||
Test pipenv locally. If tests pass, you can go ahead and make a PR to merge whatever you want to release.
|
||||
|
||||
```bash
|
||||
$ export PIPENV_PYTHON=3.8
|
||||
$ pipenv install --dev && pytest -ra tests
|
||||
$ export PIPENV_PYTHON=2.7
|
||||
$ pipenv install --dev && pytest -ra tests
|
||||
```
|
||||
|
||||
## Check Spelling in Documentation
|
||||
|
||||
Pipenv now leverages `sphinxcontrib.spelling` to help ensure documentation does not contain typographical mistakes. To validate documentation, please make sure to rebuild and rectify any documentation issues before pushing the new release:
|
||||
|
||||
```console
|
||||
$ pipenv shell
|
||||
$ cd docs
|
||||
$ make clean && make html
|
||||
$ make spelling
|
||||
```
|
||||
|
||||
Validate the results, adding any new exceptions to `docs/spelling_wordlist.txt`.
|
||||
|
||||
|
||||
## Releasing
|
||||
|
||||
1. Set a version: `pipenv run inv release.bump-version --trunc-month --pre --tag=a` - this will truncate the current month, creating an alpha pre-release, e.g. `2020.4.1a1`
|
||||
a. **Note**: You can pass `--tag=b` or `--tag=rc` here as well
|
||||
2. `make check` - This has the side-effect of producing wheels
|
||||
3. `make tests`- Runs tests locally
|
||||
4. `make upload-test` - This uploads artifacts to test-pypi
|
||||
5. Consume the version on test pypi, ensure that version is functioning.
|
||||
6. Push the pre-release to github & wait for CI to pass
|
||||
7. Create a new tag, e.g. `v2020.4.1a1` and push it to github -- this can be achieved via `pipenv run inv release.tag-version --push`
|
||||
8. The github action will automatically build and push the prerelease to `PyPI`
|
||||
9. Once a release is pushed, the action will update `master` with a new `dev` version
|
||||
10. Review any pull requests and issues that should be resolved before releasing the final version
|
||||
11. The process is identical for releasing a standard release, except the `release.bump-version` command is called without any arguments.
|
||||
|
||||
|
||||
If in doubt, follow the basic instructions below.
|
||||
|
||||
## Uploading the release
|
||||
|
||||
1. Get set up on [Test PyPI](https://test.pypi.org/)
|
||||
2. [Use Test PyPI](https://packaging.python.org/guides/using-testpypi/) to upload the package, make sure the `README` renders, test that it installs okay, and so on
|
||||
3. Get credentials to co-maintain the pipenv project on PyPI.org -- **SPOF alert**
|
||||
4. Set the version number to [a pre-release identifier](https://www.python.org/dev/peps/pep-0440/#pre-release-separators)
|
||||
5. Package and upload pipenv [to PyPI](https://pypi.org/project/pipenv/#history) as a pre-release/alpha
|
||||
6. Publicize on distutils-sig, [Discourse](https://discuss.python.org/c/packaging), and the relevant GitHub issue(s)
|
||||
a. write up diplomatic notification
|
||||
7. Recruit manual testing ([example](https://pad.sfconservancy.org/p/help-test-pipenv-2020-03-26)) for workflows we don't account for
|
||||
8. Wait a week, then update version number to a canonical release and re-release on PyPI.org
|
||||
10. Publicize on lists, Discourse, GitHub issues
|
||||
|
||||
|
||||
|
||||
## Looking ahead
|
||||
|
||||
Most of the pipenv related ecosystem libraries are using [GitHub actions](https://github.com/sarugaku/vistir/blob/master/.github/workflows/pypi_upload.yml) to automate releases when tags are pushed. Most likely we will look to move in this direction and simplify the process.
|
||||
@@ -1,107 +0,0 @@
|
||||
name: Pipenv Build Rules
|
||||
trigger:
|
||||
batch: true
|
||||
branches:
|
||||
include:
|
||||
- master
|
||||
paths:
|
||||
exclude:
|
||||
- docs/
|
||||
- news/
|
||||
- peeps/
|
||||
- examples/
|
||||
- pytest.ini
|
||||
- README.md
|
||||
- pipenv/*.txt
|
||||
- CHANGELOG.rst
|
||||
- CONTRIBUTING.md
|
||||
- CODE_OF_CONDUCT.md
|
||||
- .gitignore
|
||||
- .gitattributes
|
||||
- .editorconfig
|
||||
|
||||
variables:
|
||||
- group: CI
|
||||
|
||||
jobs:
|
||||
- job: TestLinux
|
||||
pool:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
strategy:
|
||||
matrix:
|
||||
Python27:
|
||||
python.version: '2.7'
|
||||
python.architecture: x64
|
||||
Python36:
|
||||
python.version: '3.6'
|
||||
python.architecture: x64
|
||||
Python37:
|
||||
python.version: '3.7'
|
||||
python.architecture: x64
|
||||
maxParallel: 4
|
||||
steps:
|
||||
- template: .azure-pipelines/steps/run-tests.yml
|
||||
parameters:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
|
||||
- job: TestVendoring
|
||||
pool:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
variables:
|
||||
python.version: '3.7'
|
||||
python.architecture: x64
|
||||
steps:
|
||||
- template: .azure-pipelines/steps/run-vendor-scripts.yml
|
||||
parameters:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
|
||||
- job: TestPackaging
|
||||
pool:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
variables:
|
||||
python.version: '3.7'
|
||||
python.architecture: x64
|
||||
steps:
|
||||
- template: .azure-pipelines/steps/build-package.yml
|
||||
parameters:
|
||||
vmImage: 'Ubuntu-16.04'
|
||||
|
||||
- job: TestWindows
|
||||
pool:
|
||||
vmImage: windows-2019
|
||||
strategy:
|
||||
matrix:
|
||||
Python27:
|
||||
python.version: '2.7'
|
||||
python.architecture: x64
|
||||
Python36:
|
||||
python.version: '3.6'
|
||||
python.architecture: x64
|
||||
Python37:
|
||||
python.version: '3.7'
|
||||
python.architecture: x64
|
||||
maxParallel: 4
|
||||
steps:
|
||||
- template: .azure-pipelines/steps/run-tests.yml
|
||||
parameters:
|
||||
vmImage: windows-2019
|
||||
|
||||
- job: TestMacOS
|
||||
pool:
|
||||
vmImage: macOS-10.13
|
||||
strategy:
|
||||
matrix:
|
||||
Python27:
|
||||
python.version: '2.7'
|
||||
python.architecture: x64
|
||||
Python36:
|
||||
python.version: '3.6'
|
||||
python.architecture: x64
|
||||
Python37:
|
||||
python.version: '3.7'
|
||||
python.architecture: x64
|
||||
maxParallel: 4
|
||||
steps:
|
||||
- template: .azure-pipelines/steps/run-tests.yml
|
||||
parameters:
|
||||
vmImage: macOS-10.13
|
||||
@@ -1,7 +0,0 @@
|
||||
version: '3'
|
||||
services:
|
||||
pipenv-tests:
|
||||
image: kennethreitz/pipenv-tests
|
||||
command: bash /pipenv/run-tests.sh
|
||||
volumes:
|
||||
- .:/pipenv
|
||||
+1
-1
@@ -17,4 +17,4 @@ help:
|
||||
# Catch-all target: route all unknown targets to Sphinx using the new
|
||||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
||||
%: Makefile
|
||||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
Vendored
+2
-2
@@ -84,9 +84,9 @@ var Konami = function (callback) {
|
||||
},
|
||||
touchendHandler: function () {
|
||||
konami.iphone.input.push(konami.iphone.check_direction());
|
||||
|
||||
|
||||
if (konami.iphone.input.length > konami.iphone.keys.length) konami.iphone.input.shift();
|
||||
|
||||
|
||||
if (konami.iphone.input.length === konami.iphone.keys.length) {
|
||||
var match = true;
|
||||
for (var i = 0; i < konami.iphone.keys.length; i++) {
|
||||
|
||||
Vendored
+1
-1
@@ -69,7 +69,7 @@
|
||||
<style>.github-corner:hover .octo-arm{animation:octocat-wave 560ms ease-in-out}@keyframes octocat-wave{0%,100%{transform:rotate(0)}20%,60%{transform:rotate(-25deg)}40%,80%{transform:rotate(10deg)}}@media (max-width:500px){.github-corner:hover .octo-arm{animation:none}.github-corner .octo-arm{animation:octocat-wave 560ms ease-in-out}}</style>
|
||||
|
||||
|
||||
<!-- That was not a hack. That was art.
|
||||
<!-- That was not a hack. That was art. -->
|
||||
|
||||
<!-- UserVoice JavaScript SDK (only needed once on a page) -->
|
||||
<script>(function(){var uv=document.createElement('script');uv.type='text/javascript';uv.async=true;uv.src='//widget.uservoice.com/f4AQraEfwInlMzkexfRLg.js';var s=document.getElementsByTagName('script')[0];s.parentNode.insertBefore(uv,s)})()</script>
|
||||
|
||||
Vendored
+9
-9
@@ -46,23 +46,23 @@
|
||||
<li><a href="https://pipenv-pipes.readthedocs.io/en/latest/">Pipenv-Pipes</a></li>
|
||||
</ul>
|
||||
|
||||
<p>More projects founded by <a href="http://kennethreitz.org/">Kenneth Reitz</a>:</p>
|
||||
<p>More projects founded by <a href="https://kenreitz.org">Kenneth Reitz</a>:</p>
|
||||
<ul>
|
||||
<li><a href="http://pep8.org/">pep8.org</a></li>
|
||||
<li><a href="http://httpbin.org/">httpbin.org</a></li>
|
||||
<li><a href="https://pep8.org/">pep8.org</a></li>
|
||||
<li><a href="https://httpbin.org/">httpbin.org</a></li>
|
||||
<li><a href="https://howtopython.org">HowToPython.org</a></li>
|
||||
<li><a href="http://python-guide.org">The Python Guide</a></li>
|
||||
<li><a href="http://python-requests.org/">Requests: HTTP for Humans</a></li>
|
||||
<li><a href="https://github.com/kennethreitz/maya">Maya: Datetimes for Humans</a></li>
|
||||
<li><a href="https://github.com/kennethreitz/records">Records: SQL for Humans</a></li>
|
||||
<li><a href="https://frostming.github.io/legit">Legit: Git for Humans</a></li>
|
||||
<li><a href="https://python-guide.org">The Python Guide</a></li>
|
||||
<li><a href="https://requests.readthedocs.io">Requests: HTTP for Humans</a></li>
|
||||
<li><a href="https://github.com/timofurrer/maya">Maya: Datetimes for Humans</a></li>
|
||||
<li><a href="https://github.com/kennethreitz-archive/records">Records: SQL for Humans</a></li>
|
||||
<li><a href="https://frostming.github.io/legit/">Legit: Git for Humans</a></li>
|
||||
<li><a href="http://docs.python-tablib.org/en/latest/">Tablib: Tabular Datasets</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3>Useful Links</h3>
|
||||
<ul>
|
||||
<li><a href="http://docs.python-requests.org/en/latest/community/recommended/">Recommended Packages and Extensions</a></li>
|
||||
<li><a href="https://requests.readthedocs.io/en/latest/community/recommended/">Recommended Packages and Extensions</a></li>
|
||||
|
||||
<p></p>
|
||||
|
||||
|
||||
Vendored
+14
-14
@@ -1,6 +1,6 @@
|
||||
<p class="logo">
|
||||
<a href="{{ pathto(master_doc) }}">
|
||||
<img class="logo" src="{{ pathto('_static/pipenv.png', 1) }}" title="https://kennethreitz.org/tattoos"/>
|
||||
<img class="logo" src="{{ pathto('_static/pipenv.png', 1) }}" title="Gift-wrapped box w/ 'pipenv' on the ribbon"/>
|
||||
</a>
|
||||
</p>
|
||||
|
||||
@@ -50,31 +50,31 @@
|
||||
<li><a href="https://pipenv-pipes.readthedocs.io/en/latest/">Pipenv-Pipes</a></li>
|
||||
</ul>
|
||||
|
||||
<p>More projects founded by <a href="http://kennethreitz.org/">Kenneth Reitz</a>:</p>
|
||||
<p>More projects founded by <a href="https://kenreitz.org">Kenneth Reitz</a>:</p>
|
||||
<ul>
|
||||
<li><a href="http://pep8.org/">pep8.org</a></li>
|
||||
<li><a href="http://httpbin.org/">httpbin.org</a></li>
|
||||
<li><a href="https://pep8.org/">pep8.org</a></li>
|
||||
<li><a href="https://httpbin.org/">httpbin.org</a></li>
|
||||
<li><a href="https://howtopython.org">HowToPython.org</a></li>
|
||||
<li><a href="http://python-guide.org">The Python Guide</a></li>
|
||||
<li><a href="http://python-requests.org/">Requests: HTTP for Humans</a></li>
|
||||
<li><a href="https://github.com/kennethreitz/records">Records: SQL for Humans</a></li>
|
||||
<li><a href="https://frostming.github.io/legit">Legit: Git for Humans</a></li>
|
||||
<li><a href="https://python-guide.org">The Python Guide</a></li>
|
||||
<li><a href="https://requests.readthedocs.io">Requests: HTTP for Humans</a></li>
|
||||
<li><a href="https://github.com/timofurrer/maya">Maya: Datetimes for Humans</a></li>
|
||||
<li><a href="https://github.com/kennethreitz-archive/records">Records: SQL for Humans</a></li>
|
||||
<li><a href="https://frostming.github.io/legit/">Legit: Git for Humans</a></li>
|
||||
<li><a href="http://docs.python-tablib.org/en/latest/">Tablib: Tabular Datasets</a></li>
|
||||
<li><a href="http://markdownplease.com">Markdown, Please!</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3>Useful Links</h3>
|
||||
<ul>
|
||||
<li><a href="http://docs.python-requests.org/en/latest/community/recommended/">Recommended Packages and Extensions</a></li>
|
||||
<li><a href="https://requests.readthedocs.io/en/latest/community/recommended/">Recommended Packages and Extensions</a></li>
|
||||
|
||||
<p></p>
|
||||
|
||||
<li><a href="http://github.com/pypa/pipenv">Pipenv @ GitHub</a></li>
|
||||
<li><a href="http://pypi.org/project/pipenv">Pipenv @ PyPI</a></li>
|
||||
<li><a href="https://github.com/pypa/pipenv">Pipenv @ GitHub</a></li>
|
||||
<li><a href="https://pypi.org/project/pipenv">Pipenv @ PyPI</a></li>
|
||||
<li><a href="https://launchpad.net/~pypa/+archive/ubuntu/ppa">Pipenv PPA (PyPA)</a></li>
|
||||
<li><a href="http://github.com/pypa/pipenv/issues">Issue Tracker</a></li>
|
||||
<li><a href="https://github.com/pypa/pipenv/issues">Issue Tracker</a></li>
|
||||
<hr>
|
||||
<li><a href="http://pipenv-ja.readthedocs.io/ja/translate-ja/">日本語</a></li>
|
||||
<li><a href="https://pipenv-ja.readthedocs.io/ja/translate-ja/">日本語</a></li>
|
||||
<li><a href="https://pipenv-es.readthedocs.io/es/latest/">Español</a></li>
|
||||
</ul>
|
||||
|
||||
+106
-66
@@ -41,7 +41,7 @@ Very fancy.
|
||||
☤ Using a PyPI Mirror
|
||||
----------------------------
|
||||
|
||||
If you'd like to override the default PyPI index urls with the url for a PyPI mirror, you can use the following::
|
||||
If you would like to override the default PyPI index URLs with the URL for a PyPI mirror, you can use the following::
|
||||
|
||||
$ pipenv install --pypi-mirror <mirror_url>
|
||||
|
||||
@@ -58,7 +58,6 @@ Alternatively, you can set the ``PIPENV_PYPI_MIRROR`` environment variable.
|
||||
☤ Injecting credentials into Pipfiles via environment variables
|
||||
-----------------------------------------------------------------
|
||||
|
||||
|
||||
Pipenv will expand environment variables (if defined) in your Pipfile. Quite
|
||||
useful if you need to authenticate to a private PyPI::
|
||||
|
||||
@@ -71,10 +70,18 @@ Luckily - pipenv will hash your Pipfile *before* expanding environment
|
||||
variables (and, helpfully, will substitute the environment variables again when
|
||||
you install from the lock file - so no need to commit any secrets! Woo!)
|
||||
|
||||
If your credentials contain a special character, surround the references to the environment variables with quotation marks. For example, if your password contain a double quotation mark, surround the password variable with single quotation marks. Otherwise, you may get a ``ValueError, "No closing quotation"`` error while installing dependencies. ::
|
||||
If your credentials contain special characters, make sure they are URL-encoded as specified in `rfc3986 <https://datatracker.ietf.org/doc/html/rfc3986>`_.
|
||||
|
||||
[[source]]
|
||||
url = "https://$USERNAME:'${PASSWORD}'@mypypi.example.com/simple"
|
||||
Environment variables may be specified as ``${MY_ENVAR}`` or ``$MY_ENVAR``.
|
||||
|
||||
On Windows, ``%MY_ENVAR%`` is supported in addition to ``${MY_ENVAR}`` or ``$MY_ENVAR``.
|
||||
|
||||
Environment variables in the URL part of requirement specifiers can also be expanded, where the variable must be in the form of ``${VAR_NAME}``. Neither ``$VAR_NAME`` nor ``%VAR_NAME%`` is acceptable::
|
||||
|
||||
[[package]]
|
||||
requests = {git = "git://${USERNAME}:${PASSWORD}@private.git.com/psf/requests.git", ref = "2.22.0"}
|
||||
|
||||
Keep in mind that environment variables are expanded in runtime, leaving the entries in ``Pipfile`` or ``Pipfile.lock`` untouched. This is to avoid the accidental leakage of credentials in the source code.
|
||||
|
||||
|
||||
☤ Specifying Basically Anything
|
||||
@@ -126,6 +133,12 @@ Or you can install packages exactly as specified in ``Pipfile.lock`` using the `
|
||||
|
||||
``pipenv install --ignore-pipfile`` is nearly equivalent to ``pipenv sync``, but ``pipenv sync`` will *never* attempt to re-lock your dependencies as it is considered an atomic operation. ``pipenv install`` by default does attempt to re-lock unless using the ``--deploy`` flag.
|
||||
|
||||
You may only wish to verify your ``Pipfile.lock`` is up-to-date with dependencies specified in the ``Pipfile``, without installing::
|
||||
|
||||
$ pipenv verify
|
||||
|
||||
The command will perform a verification, and return an exit code ``1`` when dependency locking is needed. This may be useful for cases when the ``Pipfile.lock`` file is subject to version control, so this command can be used within your CI/CD pipelines.
|
||||
|
||||
Deploying System Dependencies
|
||||
/////////////////////////////
|
||||
|
||||
@@ -149,7 +162,9 @@ Anaconda uses Conda to manage packages. To reuse Conda–installed Python packag
|
||||
☤ Generating a ``requirements.txt``
|
||||
-----------------------------------
|
||||
|
||||
You can convert a ``Pipfile`` and ``Pipfile.lock`` into a ``requirements.txt`` file very easily, and get all the benefits of extras and other goodies we have included.
|
||||
You can convert a ``Pipfile`` and ``Pipfile.lock`` into a ``requirements.txt``
|
||||
file very easily, and get all the benefits of extras and other goodies we have
|
||||
included.
|
||||
|
||||
Let's take this ``Pipfile``::
|
||||
|
||||
@@ -160,7 +175,10 @@ Let's take this ``Pipfile``::
|
||||
[packages]
|
||||
requests = {version="*"}
|
||||
|
||||
And generate a ``requirements.txt`` out of it::
|
||||
[dev-packages]
|
||||
pytest = {version="*"}
|
||||
|
||||
And generate a set of requirements out of it with only the default dependencies::
|
||||
|
||||
$ pipenv lock -r
|
||||
chardet==3.0.4
|
||||
@@ -169,22 +187,41 @@ And generate a ``requirements.txt`` out of it::
|
||||
idna==2.6
|
||||
urllib3==1.22
|
||||
|
||||
If you wish to generate a ``requirements.txt`` with only the development requirements you can do that too! Let's take the following ``Pipfile``::
|
||||
|
||||
[[source]]
|
||||
url = "https://pypi.python.org/simple"
|
||||
verify_ssl = true
|
||||
|
||||
[dev-packages]
|
||||
pytest = {version="*"}
|
||||
|
||||
And generate a ``requirements.txt`` out of it::
|
||||
As with other commands, passing ``--dev`` will include both the default and
|
||||
development dependencies::
|
||||
|
||||
$ pipenv lock -r --dev
|
||||
chardet==3.0.4
|
||||
requests==2.18.4
|
||||
certifi==2017.7.27.1
|
||||
idna==2.6
|
||||
urllib3==1.22
|
||||
py==1.4.34
|
||||
pytest==3.2.3
|
||||
|
||||
Finally, if you wish to generate a requirements file with only the
|
||||
development requirements you can do that too, using the ``--dev-only``
|
||||
flag::
|
||||
|
||||
$ pipenv lock -r --dev-only
|
||||
py==1.4.34
|
||||
pytest==3.2.3
|
||||
|
||||
The locked requirements are written to stdout, with shell output redirection
|
||||
used to write them to a file::
|
||||
|
||||
$ pipenv lock -r > requirements.txt
|
||||
$ pipenv lock -r --dev-only > dev-requirements.txt
|
||||
$ cat requirements.txt
|
||||
chardet==3.0.4
|
||||
requests==2.18.4
|
||||
certifi==2017.7.27.1
|
||||
idna==2.6
|
||||
urllib3==1.22
|
||||
$ cat dev-requirements.txt
|
||||
py==1.4.34
|
||||
pytest==3.2.3
|
||||
|
||||
Very fancy.
|
||||
|
||||
☤ Detection of Security Vulnerabilities
|
||||
---------------------------------------
|
||||
@@ -199,9 +236,9 @@ Example::
|
||||
django = "==1.10.1"
|
||||
|
||||
$ pipenv check
|
||||
Checking PEP 508 requirements…
|
||||
Checking PEP 508 requirements...
|
||||
Passed!
|
||||
Checking installed package safety…
|
||||
Checking installed package safety...
|
||||
|
||||
33075: django >=1.10,<1.10.3 resolved (1.10.1 installed)!
|
||||
Django before 1.8.x before 1.8.16, 1.9.x before 1.9.11, and 1.10.x before 1.10.3, when settings.DEBUG is True, allow remote attackers to conduct DNS rebinding attacks by leveraging failure to validate the HTTP Host header against settings.ALLOWED_HOSTS.
|
||||
@@ -237,16 +274,15 @@ Example::
|
||||
|
||||
.. note::
|
||||
|
||||
In order to enable this functionality while maintaining its permissive
|
||||
copyright license, `pipenv` embeds an API client key for the backend
|
||||
Safety API operated by pyup.io rather than including a full copy of the
|
||||
CC-BY-NC-SA licensed Safety-DB database. This embedded client key is
|
||||
shared across all `pipenv check` users, and hence will be subject to
|
||||
API access throttling based on overall usage rather than individual
|
||||
client usage.
|
||||
Each month, `PyUp.io` updates the ``safety`` database of
|
||||
insecure Python packages and `makes it available to the
|
||||
community for free <https://pyup.io/safety/>`__. Pipenv
|
||||
makes an API call to retrieve those results and use them
|
||||
each time you run ``pipenv check`` to show you vulnerable
|
||||
dependencies.
|
||||
|
||||
You can also use your own safety API key by setting the
|
||||
environment variable ``PIPENV_PYUP_API_KEY``.
|
||||
For more up-to-date vulnerability data, you may also use your own safety
|
||||
API key by setting the environment variable ``PIPENV_PYUP_API_KEY``.
|
||||
|
||||
|
||||
☤ Community Integrations
|
||||
@@ -276,7 +312,7 @@ Works in progress:
|
||||
Pipenv allows you to open any Python module that is installed (including ones in your codebase), with the ``$ pipenv open`` command::
|
||||
|
||||
$ pipenv install -e git+https://github.com/kennethreitz/background.git#egg=background
|
||||
Installing -e git+https://github.com/kennethreitz/background.git#egg=background…
|
||||
Installing -e git+https://github.com/kennethreitz/background.git#egg=background...
|
||||
...
|
||||
Updated Pipfile.lock!
|
||||
|
||||
@@ -308,17 +344,17 @@ This is a very fancy feature, and we're very proud of it::
|
||||
python_version = "3.6"
|
||||
|
||||
$ pipenv install
|
||||
Warning: Python 3.6 was not found on your system…
|
||||
Warning: Python 3.6 was not found on your system...
|
||||
Would you like us to install latest CPython 3.6 with pyenv? [Y/n]: y
|
||||
Installing CPython 3.6.2 with pyenv (this may take a few minutes)…
|
||||
Installing CPython 3.6.2 with pyenv (this may take a few minutes)...
|
||||
...
|
||||
Making Python installation global…
|
||||
Creating a virtualenv for this project…
|
||||
Using /Users/kennethreitz/.pyenv/shims/python3 to create virtualenv…
|
||||
Making Python installation global...
|
||||
Creating a virtualenv for this project...
|
||||
Using /Users/kennethreitz/.pyenv/shims/python3 to create virtualenv...
|
||||
...
|
||||
No package provided, installing all dependencies.
|
||||
...
|
||||
Installing dependencies from Pipfile.lock…
|
||||
Installing dependencies from Pipfile.lock...
|
||||
🐍 ❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒❒ 5/5 — 00:00:03
|
||||
To activate this project's virtualenv, run the following:
|
||||
$ pipenv shell
|
||||
@@ -336,7 +372,7 @@ If a ``.env`` file is present in your project, ``$ pipenv shell`` and ``$ pipenv
|
||||
HELLO=WORLD⏎
|
||||
|
||||
$ pipenv run python
|
||||
Loading .env environment variables…
|
||||
Loading .env environment variables...
|
||||
Python 2.7.13 (default, Jul 18 2017, 09:17:00)
|
||||
[GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.42)] on darwin
|
||||
Type "help", "copyright", "credits" or "license" for more information.
|
||||
@@ -344,6 +380,21 @@ If a ``.env`` file is present in your project, ``$ pipenv shell`` and ``$ pipenv
|
||||
>>> os.environ['HELLO']
|
||||
'WORLD'
|
||||
|
||||
Shell like variable expansion is available in ``.env`` files using `${VARNAME}` syntax.::
|
||||
|
||||
$ cat .env
|
||||
CONFIG_PATH=${HOME}/.config/foo
|
||||
|
||||
$ pipenv run python
|
||||
Loading .env environment variables...
|
||||
Python 3.7.6 (default, Dec 19 2019, 22:52:49)
|
||||
[GCC 9.2.1 20190827 (Red Hat 9.2.1-1)] on linux
|
||||
Type "help", "copyright", "credits" or "license" for more information.
|
||||
>>> import os
|
||||
>>> os.environ['CONFIG_PATH']
|
||||
'/home/kennethreitz/.config/foo'
|
||||
|
||||
|
||||
This is very useful for keeping production credentials out of your codebase.
|
||||
We do not recommend committing ``.env`` files into source control!
|
||||
|
||||
@@ -355,6 +406,8 @@ To prevent pipenv from loading the ``.env`` file, set the ``PIPENV_DONT_LOAD_ENV
|
||||
|
||||
$ PIPENV_DONT_LOAD_ENV=1 pipenv shell
|
||||
|
||||
See `theskumar/python-dotenv <https://github.com/theskumar/python-dotenv>`_ for more information on ``.env`` files.
|
||||
|
||||
☤ Custom Script Shortcuts
|
||||
-------------------------
|
||||
|
||||
@@ -388,30 +441,13 @@ For example:
|
||||
$ pipenv run echospam "indeed"
|
||||
I am really a very silly example indeed
|
||||
|
||||
☤ Support for Environment Variables
|
||||
-----------------------------------
|
||||
You can then display the names and commands of your shortcuts by running ``pipenv scripts`` in your terminal.
|
||||
|
||||
Pipenv supports the usage of environment variables in place of authentication fragments
|
||||
in your Pipfile. These will only be parsed if they are present in the ``[[source]]``
|
||||
section. For example:
|
||||
::
|
||||
|
||||
.. code-block:: toml
|
||||
|
||||
[[source]]
|
||||
url = "https://${PYPI_USERNAME}:${PYPI_PASSWORD}@my_private_repo.example.com/simple"
|
||||
verify_ssl = true
|
||||
name = "pypi"
|
||||
|
||||
[dev-packages]
|
||||
|
||||
[packages]
|
||||
requests = {version="*", index="home"}
|
||||
maya = {version="*", index="pypi"}
|
||||
records = "*"
|
||||
|
||||
Environment variables may be specified as ``${MY_ENVAR}`` or ``$MY_ENVAR``.
|
||||
|
||||
On Windows, ``%MY_ENVAR%`` is supported in addition to ``${MY_ENVAR}`` or ``$MY_ENVAR``.
|
||||
$ pipenv scripts
|
||||
command script
|
||||
echospam echo I am really a very silly example
|
||||
|
||||
.. _configuration-with-environment-variables:
|
||||
|
||||
@@ -451,7 +487,7 @@ In addition, you can also have Pipenv stick the virtualenv in ``project/.venv``
|
||||
|
||||
Pipenv is being used in projects like `Requests`_ for declaring development dependencies and running the test suite.
|
||||
|
||||
We've currently tested deployments with both `Travis-CI`_ and `tox`_ with success.
|
||||
We have currently tested deployments with both `Travis-CI`_ and `tox`_ with success.
|
||||
|
||||
Travis CI
|
||||
/////////
|
||||
@@ -533,13 +569,17 @@ A 3rd party plugin, `tox-pipenv`_ is also available to use Pipenv natively with
|
||||
☤ Shell Completion
|
||||
------------------
|
||||
|
||||
To enable completion in fish, add this to your config::
|
||||
To enable completion in fish, add this to your configuration::
|
||||
|
||||
eval (pipenv --completion)
|
||||
eval (env _PIPENV_COMPLETE=fish_source pipenv)
|
||||
|
||||
Alternatively, with bash or zsh, add this to your config::
|
||||
Alternatively, with zsh, add this to your configuration::
|
||||
|
||||
eval "$(pipenv --completion)"
|
||||
eval "$(_PIPENV_COMPLETE=zsh_source pipenv)"
|
||||
|
||||
Alternatively, with bash, add this to your configuration::
|
||||
|
||||
eval "$(_PIPENV_COMPLETE=bash_source pipenv)"
|
||||
|
||||
Magic shell completions are now enabled!
|
||||
|
||||
@@ -571,9 +611,9 @@ at all, use the `PIP_IGNORE_INSTALLED` setting::
|
||||
|
||||
There is a subtle but very important distinction to be made between **applications** and **libraries**. This is a very common source of confusion in the Python community.
|
||||
|
||||
Libraries provide reusable functionality to other libraries and applications (let's use the umbrella term **projects** here). They are required to work alongside other libraries, all with their own set of subdependencies. They define **abstract dependencies**. To avoid version conflicts in subdependencies of different libraries within a project, libraries should never ever pin dependency versions. Although they may specify lower or (less frequently) upper bounds, if they rely on some specific feature/fix/bug. Library dependencies are specified via ``install_requires`` in ``setup.py``.
|
||||
Libraries provide reusable functionality to other libraries and applications (let's use the umbrella term **projects** here). They are required to work alongside other libraries, all with their own set of sub-dependencies. They define **abstract dependencies**. To avoid version conflicts in sub-dependencies of different libraries within a project, libraries should never ever pin dependency versions. Although they may specify lower or (less frequently) upper bounds, if they rely on some specific feature/fix/bug. Library dependencies are specified via ``install_requires`` in ``setup.py``.
|
||||
|
||||
Libraries are ultimately meant to be used in some **application**. Applications are different in that they usually are not depended on by other projects. They are meant to be deployed into some specific environment and only then should the exact versions of all their dependencies and subdependencies be made concrete. To make this process easier is currently the main goal of Pipenv.
|
||||
Libraries are ultimately meant to be used in some **application**. Applications are different in that they usually are not depended on by other projects. They are meant to be deployed into some specific environment and only then should the exact versions of all their dependencies and sub-dependencies be made concrete. To make this process easier is currently the main goal of Pipenv.
|
||||
|
||||
To summarize:
|
||||
|
||||
|
||||
+123
-9
@@ -10,10 +10,11 @@ This document covers some of Pipenv's more basic features.
|
||||
☤ Example Pipfile & Pipfile.lock
|
||||
--------------------------------
|
||||
|
||||
Pipfiles contain information for the dependencies of the project, and supercede
|
||||
the requirements.txt present in Python projects. You should add Pipfile to your
|
||||
Git repository, and let users who clone the repository know that they need only
|
||||
install Pipenv, and type ``pipenv install``. Pipenv is a reference
|
||||
Pipfiles contain information for the dependencies of the project, and supersedes
|
||||
the requirements.txt file used in most Python projects. You should add a Pipfile in the
|
||||
Git repository letting users who clone the repository know the only thing required would be
|
||||
installing Pipenv in the machine and typing ``pipenv install``. Pipenv is a reference
|
||||
|
||||
implementation for using Pipfile.
|
||||
|
||||
.. _example_files:
|
||||
@@ -131,7 +132,7 @@ Example Pipfile.lock
|
||||
|
||||
- Generally, keep both ``Pipfile`` and ``Pipfile.lock`` in version control.
|
||||
- Do not keep ``Pipfile.lock`` in version control if multiple versions of Python are being targeted.
|
||||
- Specify your target Python version in your `Pipfile`'s ``[requires]`` section. Ideally, you should only have one target Python version, as this is a deployment tool. ``python_version`` should be in the format ``X.Y`` and ``python_full_version`` should be in ``X.Y.Z`` format.
|
||||
- Specify your target Python version in your `Pipfile`'s ``[requires]`` section. Ideally, you should only have one target Python version, as this is a deployment tool. ``python_version`` should be in the format ``X.Y`` (or ``X``) and ``python_full_version`` should be in ``X.Y.Z`` format.
|
||||
- ``pipenv install`` is fully compatible with ``pip install`` syntax, for which the full documentation can be found `here <https://pip.pypa.io/en/stable/user_guide/#installing-packages>`_.
|
||||
- Note that the ``Pipfile`` uses the `TOML Spec <https://github.com/toml-lang/toml#user-content-spec>`_.
|
||||
|
||||
@@ -216,7 +217,7 @@ To make inclusive or exclusive version comparisons you can use: ::
|
||||
|
||||
The use of ``~=`` is preferred over the ``==`` identifier as the latter prevents pipenv from updating the packages: ::
|
||||
|
||||
$ pipenv install "requests~=2.2" # locks the major version of the package (this is equivalent to using ==2.*)
|
||||
$ pipenv install "requests~=2.2" # locks the major version of the package (this is equivalent to using >=2.2, ==2.*)
|
||||
|
||||
To avoid installing a specific version you can use the ``!=`` identifier.
|
||||
|
||||
@@ -371,7 +372,7 @@ You can install packages with pipenv from git and other version control systems
|
||||
|
||||
<vcs_type>+<scheme>://<location>/<user_or_organization>/<repository>@<branch_or_tag>#egg=<package_name>
|
||||
|
||||
The only optional section is the ``@<branch_or_tag>`` section. When using git over SSH, you may use the shorthand vcs and scheme alias ``git+git@<location>:<user_or_organization>/<repository>@<branch_or_tag>#<package_name>``. Note that this is translated to ``git+ssh://git@<location>`` when parsed.
|
||||
The only optional section is the ``@<branch_or_tag>`` section. When using git over SSH, you may use the shorthand vcs and scheme alias ``git+git@<location>:<user_or_organization>/<repository>@<branch_or_tag>#egg=<package_name>``. Note that this is translated to ``git+ssh://git@<location>`` when parsed.
|
||||
|
||||
Note that it is **strongly recommended** that you install any version-controlled dependencies in editable mode, using ``pipenv install -e``, in order to ensure that dependency resolution can be performed with an up to date copy of the repository each time it is performed, and that it includes all known dependencies.
|
||||
|
||||
@@ -409,5 +410,118 @@ production environments for reproducible builds.
|
||||
.. note::
|
||||
|
||||
If you'd like a ``requirements.txt`` output of the lockfile, run ``$ pipenv lock -r``.
|
||||
This will include all hashes, however (which is great!). To get a ``requirements.txt``
|
||||
without hashes, use ``$ pipenv run pip freeze``.
|
||||
This will not include hashes, however. To get a ``requirements.txt``
|
||||
you can also use ``$ pipenv run pip freeze``.
|
||||
|
||||
|
||||
☤ Pipenv and Docker Containers
|
||||
------------------------------
|
||||
|
||||
In general, you should not have Pipenv inside a linux container image, since
|
||||
it is a build tool. If you want to use it to build, and install the run time
|
||||
dependencies for your application, you can use a multi stage build for creating
|
||||
a virtual environment with your dependencies. In this approach,
|
||||
Pipenv in installed in the base layer, it is then used to create the virtual
|
||||
environment. In a later stage, in a ``runtime`` layer the virtual environment
|
||||
is copied from the base layer, the layer containing pipenv and other build
|
||||
dependencies is discarded.
|
||||
This results in a smaller image, which can still run your application.
|
||||
Here is an example ``Dockerfile``, which you can use as a starting point for
|
||||
doing a multi stage build for your application::
|
||||
|
||||
FROM docker.io/python:3.9 AS builder
|
||||
|
||||
RUN pip install --user pipenv
|
||||
|
||||
# Tell pipenv to create venv in the current directory
|
||||
ENV PIPENV_VENV_IN_PROJECT=1
|
||||
|
||||
# Pipefile contains requests
|
||||
ADD Pipfile.lock Pipfile /usr/src/
|
||||
|
||||
WORKDIR /usr/src
|
||||
|
||||
# NOTE: If you install binary packages required for a python module, you need
|
||||
# to install them again in the runtime. For example, if you need to install pycurl
|
||||
# you need to have pycurl build dependencies libcurl4-gnutls-dev and libcurl3-gnutls
|
||||
# In the runtime container you need only libcurl3-gnutls
|
||||
|
||||
# RUN apt install -y libcurl3-gnutls libcurl4-gnutls-dev
|
||||
|
||||
RUN /root/.local/bin/pipenv sync
|
||||
|
||||
RUN /usr/src/.venv/bin/python -c "import requests; print(requests.__version__)"
|
||||
|
||||
FROM docker.io/python:3.9 AS runtime
|
||||
|
||||
RUN mkdir -v /usr/src/venv
|
||||
|
||||
COPY --from=builder /usr/src/.venv/ /usr/src/venv/
|
||||
|
||||
RUN /usr/src/venv/bin/python -c "import requests; print(requests.__version__)"
|
||||
|
||||
# HERE GOES ANY CODE YOU NEED TO ADD TO CREATE YOUR APPLICATION'S IMAGE
|
||||
# For example
|
||||
# RUN apt install -y libcurl3-gnutls
|
||||
# RUN adduser --uid 123123 coolio
|
||||
|
||||
WORKDIR /usr/src/
|
||||
|
||||
USER coolio
|
||||
|
||||
CMD ["./venv/bin/python", "-m", "run.py"]
|
||||
|
||||
.. Note::
|
||||
|
||||
Pipenv is not meant to run as root. However, in the multi stage build above
|
||||
it is done never the less. A calculated risk, since the intermediatiary image
|
||||
is discarded.
|
||||
The runtime image later shows that you should create a user and user it to
|
||||
run your applicaion.
|
||||
**Once again, you should not run pipenv as root (or Admin on Windows) normally.
|
||||
This could lead to breakage of your Python installation, or even your complete
|
||||
OS.**
|
||||
|
||||
When you build an image with this example (assuming requests is found in Pipefile), you
|
||||
will see that ``requests`` is installed in the ``runtime`` image::
|
||||
|
||||
$ sudo docker build --no-cache -t oz/123:0.1 .
|
||||
Sending build context to Docker daemon 1.122MB
|
||||
Step 1/12 : FROM docker.io/python:3.9 AS builder
|
||||
---> 81f391f1a7d7
|
||||
Step 2/12 : RUN pip install --user pipenv
|
||||
---> Running in b83ed3c28448
|
||||
... trimmed ...
|
||||
---> 848743eb8c65
|
||||
Step 4/12 : ENV PIPENV_VENV_IN_PROJECT=1
|
||||
---> Running in 814e6f5fec5b
|
||||
Removing intermediate container 814e6f5fec5b
|
||||
---> 20167b4a13e1
|
||||
Step 5/12 : ADD Pipfile.lock Pipfile /usr/src/
|
||||
---> c7632cb3d5bd
|
||||
Step 6/12 : WORKDIR /usr/src
|
||||
---> Running in 1d75c6cfce10
|
||||
Removing intermediate container 1d75c6cfce10
|
||||
---> 2dcae54cc2e5
|
||||
Step 7/12 : RUN /root/.local/bin/pipenv sync
|
||||
---> Running in 1a00b326b1ee
|
||||
Creating a virtualenv for this project...
|
||||
... trimmed ...
|
||||
✔ Successfully created virtual environment!
|
||||
Virtualenv location: /usr/src/.venv
|
||||
Installing dependencies from Pipfile.lock (fe5a22)...
|
||||
... trimmed ...
|
||||
Step 8/12 : RUN /usr/src/.venv/bin/python -c "import requests; print(requests.__version__)"
|
||||
---> Running in 3a66e3ce4a11
|
||||
2.27.1
|
||||
Removing intermediate container 3a66e3ce4a11
|
||||
---> 1db657d0ac17
|
||||
Step 9/12 : FROM docker.io/python:3.9 AS runtime
|
||||
... trimmed ...
|
||||
Step 12/12 : RUN /usr/src/venv/bin/python -c "import requests; print(requests.__version__)"
|
||||
---> Running in fa39ba4080c5
|
||||
2.27.1
|
||||
Removing intermediate container fa39ba4080c5
|
||||
---> 2b1c90fd414e
|
||||
Successfully built 2b1c90fd414e
|
||||
Successfully tagged oz/123:0.1
|
||||
|
||||
+7
-10
@@ -1,4 +1,3 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# pipenv documentation build configuration file, created by
|
||||
# sphinx-quickstart on Mon Jan 30 13:28:36 2017.
|
||||
@@ -18,7 +17,6 @@
|
||||
#
|
||||
import os
|
||||
|
||||
|
||||
# Path hackery to get current version number.
|
||||
here = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
@@ -56,9 +54,9 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'pipenv'
|
||||
copyright = u'2020. A project founded by <a href="http://kennethreitz.com/pages/open-projects.html">Kenneth Reitz</a>'
|
||||
author = u'Python Packaging Authority'
|
||||
project = 'pipenv'
|
||||
copyright = '2020. A project founded by <a href="http://kennethreitz.com/pages/open-projects.html">Kenneth Reitz</a>'
|
||||
author = 'Python Packaging Authority'
|
||||
|
||||
# The version info for the project you're documenting, acts as replacement for
|
||||
# |version| and |release|, also used in various other places throughout the
|
||||
@@ -87,7 +85,6 @@ pygments_style = 'sphinx'
|
||||
# If true, `todo` and `todoList` produce output, else they produce nothing.
|
||||
todo_include_todos = True
|
||||
|
||||
|
||||
# -- Options for HTML output ----------------------------------------------
|
||||
|
||||
# The theme to use for HTML and HTML Help pages. See the documentation for
|
||||
@@ -155,8 +152,8 @@ latex_elements = {
|
||||
# (source start file, target name, title,
|
||||
# author, documentclass [howto, manual, or own class]).
|
||||
latex_documents = [
|
||||
(master_doc, 'pipenv.tex', u'pipenv Documentation',
|
||||
u'Kenneth Reitz', 'manual'),
|
||||
(master_doc, 'pipenv.tex', 'pipenv Documentation',
|
||||
'Kenneth Reitz', 'manual'),
|
||||
]
|
||||
|
||||
|
||||
@@ -165,7 +162,7 @@ latex_documents = [
|
||||
# One entry per manual page. List of tuples
|
||||
# (source start file, name, description, authors, manual section).
|
||||
man_pages = [
|
||||
(master_doc, 'pipenv', u'pipenv Documentation',
|
||||
(master_doc, 'pipenv', 'pipenv Documentation',
|
||||
[author], 1)
|
||||
]
|
||||
|
||||
@@ -176,7 +173,7 @@ man_pages = [
|
||||
# (source start file, target name, title, author,
|
||||
# dir menu entry, description, category)
|
||||
texinfo_documents = [
|
||||
(master_doc, 'pipenv', u'pipenv Documentation',
|
||||
(master_doc, 'pipenv', 'pipenv Documentation',
|
||||
author, 'pipenv', 'One line description of project.',
|
||||
'Miscellaneous'),
|
||||
]
|
||||
|
||||
+50
-37
@@ -8,13 +8,7 @@ contributing to the Pipenv project is *very* generous of you.
|
||||
|
||||
This document lays out guidelines and advice for contributing to this project.
|
||||
If you're thinking of contributing, please start by reading this document and
|
||||
getting a feel for how contributing to this project works. If you have any
|
||||
questions, feel free to reach out to either `Dan Ryan`_, `Tzu-ping Chung`_,
|
||||
or `Nate Prewitt`_, the primary maintainers.
|
||||
|
||||
.. _Dan Ryan: https://github.com/techalchemy
|
||||
.. _Tzu-ping Chung: https://github.com/uranusjr
|
||||
.. _Nate Prewitt: https://github.com/nateprewitt
|
||||
getting a feel for how contributing to this project works.
|
||||
|
||||
The guide is split into sections based on the type of contribution you're
|
||||
thinking of making, with a section that covers general guidelines for all
|
||||
@@ -29,16 +23,15 @@ Be Cordial
|
||||
|
||||
**Be cordial or be on your way**. *—Kenneth Reitz*
|
||||
|
||||
.. _be cordial or be on your way: https://kennethreitz.org/essays/2013/01/27/be-cordial-or-be-on-your-way
|
||||
|
||||
Pipenv has one very important rule governing all forms of contribution,
|
||||
including reporting bugs or requesting features. This golden rule is
|
||||
"`be cordial or be on your way`_".
|
||||
"`be cordial or be on your way`_"
|
||||
|
||||
**All contributions are welcome**, as long as
|
||||
everyone involved is treated with respect.
|
||||
|
||||
.. _be cordial or be on your way: https://www.kennethreitz.org/essays/be-cordial-or-be-on-your-way
|
||||
|
||||
|
||||
.. _early-feedback:
|
||||
|
||||
Get Early Feedback
|
||||
@@ -75,11 +68,9 @@ answered promptly and accurately.
|
||||
|
||||
.. _Stack Overflow: https://stackoverflow.com/
|
||||
|
||||
|
||||
Code Contributions
|
||||
------------------
|
||||
|
||||
|
||||
Steps for Submitting Code
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
@@ -102,26 +93,14 @@ When contributing code, you'll want to follow this checklist:
|
||||
|
||||
The following sub-sections go into more detail on some of the points above.
|
||||
|
||||
.. _development philosophy: https://docs.pipenv.org/dev/philosophy/
|
||||
|
||||
.. _development philosophy: https://pipenv.pypa.io/en/latest/dev/philosophy/
|
||||
|
||||
.. _dev-setup:
|
||||
|
||||
Development Setup
|
||||
~~~~~~~~~~~~~~~~~
|
||||
|
||||
To get your development environment setup, run:
|
||||
|
||||
.. code-block:: sh
|
||||
|
||||
pip install -e .
|
||||
pipenv install --dev
|
||||
|
||||
|
||||
This will install the repo version of Pipenv and then install the development
|
||||
dependencies. Once that has completed, you can start developing.
|
||||
|
||||
The repo version of Pipenv must be installed over other global versions to
|
||||
The repository version of Pipenv must be installed over other global versions to
|
||||
resolve conflicts with the ``pipenv`` folder being implicitly added to ``sys.path``.
|
||||
See `pypa/pipenv#2557`_ for more details.
|
||||
|
||||
@@ -152,7 +131,7 @@ tests, the standard pytest filters are available, such as:
|
||||
Code Review
|
||||
~~~~~~~~~~~
|
||||
|
||||
Contributions will not be merged until they've been code reviewed. You should
|
||||
Contributions will not be merged until they have been code reviewed. You should
|
||||
implement any code review feedback unless you strongly object to it. In the
|
||||
event that you object to the code review feedback, you should make your case
|
||||
clearly and calmly. If, after doing so, the feedback is judged to still apply,
|
||||
@@ -171,7 +150,6 @@ a ``.tar.gz`` or universal wheel is not available, add wheels for all available
|
||||
architectures and platforms.
|
||||
|
||||
|
||||
|
||||
Documentation Contributions
|
||||
---------------------------
|
||||
|
||||
@@ -190,7 +168,6 @@ When presenting Python code, use single-quoted strings (``'hello'`` instead of
|
||||
.. _reStructuredText: http://docutils.sourceforge.net/rst.html
|
||||
.. _Sphinx: http://sphinx-doc.org/index.html
|
||||
|
||||
|
||||
.. _bug-reports:
|
||||
|
||||
Bug Reports
|
||||
@@ -205,7 +182,7 @@ be aware of the following things when filing bug reports:
|
||||
to check whether your bug report or feature request has been mentioned in
|
||||
the past. Duplicate bug reports and feature requests are a huge maintenance
|
||||
burden on the limited resources of the project. If it is clear from your
|
||||
report that you would have struggled to find the original, that's ok, but
|
||||
report that you would have struggled to find the original, that's okay, but
|
||||
if searching for a selection of words in your issue title would have found
|
||||
the duplicate then the issue will likely be closed extremely abruptly.
|
||||
2. When filing bug reports about exceptions or tracebacks, please include the
|
||||
@@ -241,11 +218,30 @@ be aware of the following things when filing bug reports:
|
||||
Run the tests
|
||||
-------------
|
||||
|
||||
Three ways of running the tests are as follows:
|
||||
Two ways of running the tests are as follows:
|
||||
|
||||
1. ``make test`` (which uses ``docker``)
|
||||
2. ``./run-tests.sh`` or ``run-tests.bat``
|
||||
3. Using pipenv:
|
||||
1. ``./run-tests.sh`` or ``run-tests.bat``
|
||||
|
||||
Note that, you override the default Python Pipenv will use with
|
||||
PIPENV_PYTHON and the Python binary name with PYTHON in case it
|
||||
is not called ``python`` on your system or in case you have many.
|
||||
Here is an example how you can override both variables (you can
|
||||
override just one too)::
|
||||
|
||||
$ PYTHON=python3.8 PIPENV_PYTHON=python3.9 run-tests.sh
|
||||
|
||||
You can also do::
|
||||
|
||||
$ PYTHON=/opt/python/python3.10/python3 run-tests.sh
|
||||
|
||||
If you need to change how pytest is invoked, see how to run the
|
||||
test suite manually. The ``run-tests.sh`` script does the same
|
||||
steps the Github CI workflow does, and as such it is recommended
|
||||
you run it before you open a PR. Taking this second approach,
|
||||
will allow you, for example, to run a single test case, or
|
||||
``fail fast`` if you need it.
|
||||
|
||||
2. Manually, which repeat the steps of the scripts above:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -253,9 +249,26 @@ Three ways of running the tests are as follows:
|
||||
$ cd pipenv
|
||||
$ git submodule sync && git submodule update --init --recursive
|
||||
$ pipenv install --dev
|
||||
$ pipenv run pytest
|
||||
$ pipenv run pytest [--any optional arguments to pytest]
|
||||
|
||||
For the last two, it is important that your environment is setup correctly, and
|
||||
The second options assumes you already have ``pipenv`` on your system.
|
||||
And simply repeats all the steps in the script above.
|
||||
|
||||
Preferably, you should be running your tests in a Linux container
|
||||
(or FreeBSD Jail or even VM). This will guarantee that you don't break
|
||||
stuff, and that the tests run in a pristine environment.
|
||||
|
||||
Consider doing, something like:
|
||||
|
||||
```
|
||||
$ docker run --rm -v $(pwd):/usr/src -it python:3.7 bash
|
||||
# inside the container
|
||||
# adduser --disabled-password debian
|
||||
# su debian && cd /usr/src/
|
||||
# bash run-tests.sh
|
||||
```
|
||||
|
||||
It is important that your environment is setup correctly, and
|
||||
this may take some work, for example, on a specific Mac installation, the following
|
||||
steps may be needed::
|
||||
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
Development Philosophy
|
||||
======================
|
||||
|
||||
Pipenv is an open but opinionated tool, created by an open but opinionated developer.
|
||||
|
||||
|
||||
Management Style
|
||||
~~~~~~~~~~~~~~~~
|
||||
|
||||
**To be updated (as of March 2020)**.
|
||||
|
||||
`Kenneth Reitz <http://kennethreitz.org>`__ is the BDFL. He has final say in any decision related to the Pipenv project. Kenneth is responsible for the direction and form of the library, as well as its presentation. In addition to making decisions based on technical merit, he is responsible for making decisions based on the development philosophy of Pipenv.
|
||||
|
||||
`Dan Ryan <http://github.com/techalchemy>`__, `Tzu-ping Chung <https://github.com/uranusjr>`__, and `Nate Prewitt <https://github.com/nateprewitt>`__ are the core contributors.
|
||||
They are responsible for triaging bug reports, reviewing pull requests and ensuring that Kenneth is kept up to speed with developments around the library.
|
||||
The day-to-day managing of the project is done by the core contributors. They are responsible for making judgements about whether or not a feature request is
|
||||
likely to be accepted by Kenneth.
|
||||
|
||||
Values
|
||||
~~~~~~
|
||||
|
||||
- Simplicity is always better than functionality.
|
||||
- Listen to everyone, then disregard it.
|
||||
- The API is all that matters. Everything else is secondary.
|
||||
- Fit the 90% use-case. Ignore the nay-sayers.
|
||||
+7
-24
@@ -29,7 +29,7 @@ usually one of the following locations:
|
||||
* ``%LOCALAPPDATA%\pipenv\pipenv\Cache`` (Windows)
|
||||
* ``~/.cache/pipenv`` (other operating systems)
|
||||
|
||||
Pipenv does not install prereleases (i.e. a version with an alpha/beta/etc.
|
||||
Pipenv does not install pre-releases (i.e. a version with an alpha/beta/etc.
|
||||
suffix, such as *1.0b1*) by default. You will need to pass the ``--pre`` flag
|
||||
in your command, or set
|
||||
|
||||
@@ -58,14 +58,9 @@ distributions, with version name like ``3.6.4`` or similar.
|
||||
------------------------------------------------------------------
|
||||
|
||||
Pipenv by default uses the Python it is installed against to create the
|
||||
virtualenv. You can set the ``--python`` option, or
|
||||
``$PYENV_ROOT/shims/python`` to let it consult pyenv when choosing the
|
||||
interpreter. See :ref:`specifying_versions` for more information.
|
||||
|
||||
If you want Pipenv to automatically “do the right thing”, you can set the
|
||||
environment variable ``PIPENV_PYTHON`` to ``$PYENV_ROOT/shims/python``. This
|
||||
will make Pipenv use pyenv’s active Python version to create virtual
|
||||
environments by default.
|
||||
virtualenv. You can set the ``--python`` option to ``$(pyenv which python)``
|
||||
to use your current pyenv interpreter. See :ref:`specifying_versions` for more
|
||||
information.
|
||||
|
||||
.. _unknown-local-diagnose:
|
||||
|
||||
@@ -101,18 +96,6 @@ This may be related to your locale setting. See :ref:`unknown-local-diagnose`
|
||||
for a possible solution.
|
||||
|
||||
|
||||
☤ ``shell`` does not show the virtualenv’s name in prompt
|
||||
---------------------------------------------------------
|
||||
|
||||
This is intentional. You can do it yourself with either shell plugins, or
|
||||
clever ``PS1`` configuration. If you really want it back, use
|
||||
|
||||
::
|
||||
|
||||
pipenv shell -c
|
||||
|
||||
instead (not available on Windows).
|
||||
|
||||
☤ Pipenv does not respect dependencies in setup.py
|
||||
--------------------------------------------------
|
||||
|
||||
@@ -124,15 +107,15 @@ for more information.
|
||||
---------------------------------------------
|
||||
|
||||
When you configure a supervisor program's ``command`` with ``pipenv run ...``, you
|
||||
need to set locale enviroment variables properly to make it work.
|
||||
need to set locale environment variables properly to make it work.
|
||||
|
||||
Add this line under ``[supervisord]`` section in ``/etc/supervisor/supervisord.conf``::
|
||||
|
||||
[supervisord]
|
||||
environment=LC_ALL='en_US.UTF-8',LANG='en_US.UTF-8'
|
||||
|
||||
☤ An exception is raised during ``Locking dependencies…``
|
||||
---------------------------------------------------------
|
||||
☤ An exception is raised during ``Locking dependencies...``
|
||||
-----------------------------------------------------------
|
||||
|
||||
Run ``pipenv lock --clear`` and try again. The lock sequence caches results
|
||||
to speed up subsequent runs. The cache may contain faulty results if a bug
|
||||
|
||||
+10
-8
@@ -32,7 +32,7 @@ Pipenv is primarily meant to provide users and developers of applications with a
|
||||
The problems that Pipenv seeks to solve are multi-faceted:
|
||||
|
||||
- You no longer need to use ``pip`` and ``virtualenv`` separately. They work together.
|
||||
- Managing a ``requirements.txt`` file `can be problematic <https://www.kennethreitz.org/essays/a-better-pip-workflow>`_, so Pipenv uses ``Pipfile`` and ``Pipfile.lock`` to separate abstract dependency declarations from the last tested combination.
|
||||
- Managing a ``requirements.txt`` file `can be problematic <https://kennethreitz.org/essays/2016/02/25/a-better-pip-workflow>`__, so Pipenv uses ``Pipfile`` and ``Pipfile.lock`` to separate abstract dependency declarations from the last tested combination.
|
||||
- Hashes are used everywhere, always. Security. Automatically expose security vulnerabilities.
|
||||
- Strongly encourage the use of the latest versions of dependencies to minimize security risks `arising from outdated components <https://www.owasp.org/index.php/Top_10-2017_A9-Using_Components_with_Known_Vulnerabilities>`_.
|
||||
- Give you insight into your dependency graph (e.g. ``$ pipenv graph``).
|
||||
@@ -48,15 +48,19 @@ You can quickly play with Pipenv right in your browser:
|
||||
Install Pipenv Today!
|
||||
---------------------
|
||||
|
||||
If you're on MacOS, you can install Pipenv easily with Homebrew. You can also use Linuxbrew on Linux using the same command::
|
||||
If you already have Python and pip, you can easily install Pipenv into your home directory::
|
||||
|
||||
$ brew install pipenv
|
||||
$ pip install --user pipenv
|
||||
|
||||
Or, if you're using Fedora 28::
|
||||
|
||||
$ sudo dnf install pipenv
|
||||
|
||||
Otherwise, refer to the :ref:`installing-pipenv` chapter for instructions.
|
||||
It's possible to install Pipenv with Homebrew on MacOS, or with Linuxbrew on Linux systems. However, **this is now discouraged**, because updates to the brewed Python distribution will break Pipenv, and perhaps all virtual environments managed by it. You'll then need to re-install Pipenv at least. If you want to give it a try despite this warning, use::
|
||||
|
||||
$ brew install pipenv
|
||||
|
||||
More detailed installation instructions can be found in the :ref:`installing-pipenv` chapter.
|
||||
|
||||
✨🍰✨
|
||||
|
||||
@@ -84,7 +88,7 @@ User Testimonials
|
||||
- Automatically finds your project home, recursively, by looking for a ``Pipfile``.
|
||||
- Automatically generates a ``Pipfile``, if one doesn't exist.
|
||||
- Automatically creates a virtualenv in a standard location.
|
||||
- Automatically adds/removes packages to a ``Pipfile`` when they are un/installed.
|
||||
- Automatically adds/removes packages to a ``Pipfile`` when they are installed or uninstalled.
|
||||
- Automatically loads ``.env`` files, if they exist.
|
||||
|
||||
The main commands are ``install``, ``uninstall``, and ``lock``, which generates a ``Pipfile.lock``. These are intended to replace ``$ pip install`` usage, as well as manual virtualenv management (to activate a virtualenv, run ``$ pipenv shell``).
|
||||
@@ -106,7 +110,7 @@ Other Commands
|
||||
- ``graph`` will show you a dependency graph of your installed dependencies.
|
||||
- ``shell`` will spawn a shell with the virtualenv activated. This shell can be deactivated by using ``exit``.
|
||||
- ``run`` will run a given command from the virtualenv, with any arguments forwarded (e.g. ``$ pipenv run python`` or ``$ pipenv run pip freeze``).
|
||||
- ``check`` checks for security vulnerabilities and asserts that PEP 508 requirements are being met by the current environment.
|
||||
- ``check`` checks for security vulnerabilities and asserts that `PEP 508 <https://www.python.org/dev/peps/pep-0508/>`_ requirements are being met by the current environment.
|
||||
|
||||
|
||||
Further Documentation Guides
|
||||
@@ -126,7 +130,6 @@ Contribution Guides
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
|
||||
dev/philosophy
|
||||
dev/contributing
|
||||
|
||||
Indices and tables
|
||||
@@ -134,4 +137,3 @@ Indices and tables
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
|
||||
+62
-36
@@ -71,7 +71,7 @@ Homebrew/Linuxbrew installer takes care of pip for you.
|
||||
===================
|
||||
|
||||
Pipenv is a dependency manager for Python projects. If you're familiar
|
||||
with Node.js' `npm`_ or Ruby's `bundler`_, it is similar in spirit to those
|
||||
with Node\.js's `npm`_ or Ruby's `bundler`_, it is similar in spirit to those
|
||||
tools. While pip can install Python packages, Pipenv is recommended as
|
||||
it's a higher-level tool that simplifies dependency management for common use
|
||||
cases.
|
||||
@@ -80,28 +80,25 @@ cases.
|
||||
.. _bundler: http://bundler.io/
|
||||
|
||||
|
||||
☤ Homebrew Installation of Pipenv
|
||||
---------------------------------
|
||||
☤ Isolated Installation of Pipenv with Pipx
|
||||
-------------------------------------------
|
||||
|
||||
`Homebrew`_ is a popular open-source package management system for macOS. For Linux users, `Linuxbrew`_ is a Linux port of that.
|
||||
`Pipx`_ is a tool to help you install and run end-user applications written in Python. It installs applications
|
||||
into an isolated and clean environment on their own. To install pipx, just run::
|
||||
|
||||
Installing pipenv via Homebrew or Linuxbrew will keep pipenv and all of its dependencies in
|
||||
an isolated virtual environment so it doesn't interfere with the rest of your
|
||||
Python installation.
|
||||
$ pip install --user pipx
|
||||
|
||||
Once you have installed Homebrew or Linuxbrew simply run::
|
||||
Once you have ``pipx`` ready on your system, continue to install Pipenv::
|
||||
|
||||
$ brew install pipenv
|
||||
$ pipx install pipenv
|
||||
|
||||
To upgrade pipenv at any time::
|
||||
|
||||
$ brew upgrade pipenv
|
||||
.. _Pipx: https://pypa.github.io/pipx/
|
||||
|
||||
|
||||
☤ Pragmatic Installation of Pipenv
|
||||
----------------------------------
|
||||
|
||||
If you have a working installation of pip, and maintain certain "toolchain" type Python modules as global utilities in your user environment, pip `user installs <https://pip.pypa.io/en/stable/user_guide/#user-installs>`_ allow for installation into your home directory. Note that due to interaction between dependencies, you should limit tools installed in this way to basic building blocks for a Python workflow like virtualenv, pipenv, tox, and similar software.
|
||||
If you have a working installation of pip, and maintain certain "tool-chain" type Python modules as global utilities in your user environment, pip `user installs <https://pip.pypa.io/en/stable/user_guide/#user-installs>`_ allow for installation into your home directory. Note that due to interaction between dependencies, you should limit tools installed in this way to basic building blocks for a Python workflow like virtualenv, pipenv, tox, and similar software.
|
||||
|
||||
To install::
|
||||
|
||||
@@ -149,6 +146,27 @@ If you don't even have pip installed, you can use this crude installation method
|
||||
$ curl https://raw.githubusercontent.com/pypa/pipenv/master/get-pipenv.py | python
|
||||
|
||||
|
||||
☤ Homebrew Installation of Pipenv(Discouraged)
|
||||
----------------------------------------------
|
||||
`Homebrew`_ is a popular open-source package management system for macOS. For Linux users, `Linuxbrew`_ is a Linux port of that.
|
||||
|
||||
Installing pipenv via Homebrew or Linuxbrew will keep pipenv and all of its dependencies in
|
||||
an isolated virtual environment so it doesn't interfere with the rest of your
|
||||
Python installation.
|
||||
|
||||
Once you have installed Homebrew or Linuxbrew simply run::
|
||||
|
||||
$ brew install pipenv
|
||||
|
||||
To upgrade pipenv at any time::
|
||||
|
||||
$ brew upgrade pipenv
|
||||
|
||||
.. Note::
|
||||
Homebrew installation is discouraged because each time the Homebrew Python is upgraded, which Pipenv depends on,
|
||||
users have to re-install Pipenv, and perhaps all virtual environments managed by it.
|
||||
|
||||
|
||||
☤ Installing packages for your project
|
||||
======================================
|
||||
|
||||
@@ -159,36 +177,44 @@ tutorial) and run::
|
||||
$ cd myproject
|
||||
$ pipenv install requests
|
||||
|
||||
.. Note::
|
||||
|
||||
Pipenv is designed to be used by non-privileged OS users. It is not meant
|
||||
to install or handle packages for the whole OS. Running Pipenv as ``root``
|
||||
or with ``sudo`` (or ``Admin`` on Windows) is highly discouraged and might
|
||||
lead to unintend breakage of your OS.
|
||||
|
||||
Pipenv will install the excellent `Requests`_ library and create a ``Pipfile``
|
||||
for you in your project's directory. The ``Pipfile`` is used to track which
|
||||
dependencies your project needs in case you need to re-install them, such as
|
||||
when you share your project with others. You should get output similar to this
|
||||
(although the exact paths shown will vary)::
|
||||
|
||||
Creating a Pipfile for this project...
|
||||
Creating a virtualenv for this project...
|
||||
Using base prefix '/usr/local/Cellar/python3/3.6.2/Frameworks/Python.framework/Versions/3.6'
|
||||
New python executable in ~/.local/share/virtualenvs/tmp-agwWamBd/bin/python3.6
|
||||
Also creating executable in ~/.local/share/virtualenvs/tmp-agwWamBd/bin/python
|
||||
Installing setuptools, pip, wheel...done.
|
||||
pipenv install requests
|
||||
Creating a virtualenv for this project...
|
||||
Pipfile: /home/user/myproject/Pipfile
|
||||
sing /home/user/.local/share/virtualenvs/pipenv-Cv0J3wbi/bin/python3.9 (3.9.9) to create virtualenv...
|
||||
Creating virtual environment...created virtual environment CPython3.9.9.final.0-64 in 1142ms
|
||||
creator CPython3Posix(dest=/home/user/.local/share/virtualenvs/myproject-R3jRVewK, clear=False, no_vcs_ignore=False, global=False)
|
||||
seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/user/.local/share/virtualenv)
|
||||
added seed packages: pip==21.3.1, setuptools==60.2.0, wheel==0.37.1
|
||||
activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
|
||||
|
||||
Virtualenv location: ~/.local/share/virtualenvs/tmp-agwWamBd
|
||||
Installing requests...
|
||||
Collecting requests
|
||||
Using cached requests-2.18.4-py2.py3-none-any.whl
|
||||
Collecting idna<2.7,>=2.5 (from requests)
|
||||
Using cached idna-2.6-py2.py3-none-any.whl
|
||||
Collecting urllib3<1.23,>=1.21.1 (from requests)
|
||||
Using cached urllib3-1.22-py2.py3-none-any.whl
|
||||
Collecting chardet<3.1.0,>=3.0.2 (from requests)
|
||||
Using cached chardet-3.0.4-py2.py3-none-any.whl
|
||||
Collecting certifi>=2017.4.17 (from requests)
|
||||
Using cached certifi-2017.7.27.1-py2.py3-none-any.whl
|
||||
Installing collected packages: idna, urllib3, chardet, certifi, requests
|
||||
Successfully installed certifi-2017.7.27.1 chardet-3.0.4 idna-2.6 requests-2.18.4 urllib3-1.22
|
||||
|
||||
Adding requests to Pipfile's [packages]...
|
||||
P.S. You have excellent taste! ✨ 🍰 ✨
|
||||
✔ Successfully created virtual environment!
|
||||
Virtualenv location: /home/user/.local/share/virtualenvs/pms-R3jRVewK
|
||||
Creating a Pipfile for this project...
|
||||
Installing requests...
|
||||
Adding requests to Pipfile's [packages]...
|
||||
Installation Succeeded
|
||||
Pipfile.lock not found, creating...
|
||||
Locking [dev-packages] dependencies...
|
||||
Locking [packages] dependencies...
|
||||
Building requirements...
|
||||
Resolving dependencies...
|
||||
✔ Success!
|
||||
Updated Pipfile.lock (fe5a22)!
|
||||
Installing dependencies from Pipfile.lock (fe5a22)...
|
||||
🐍 ▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉ 0/0 — 00:00:00
|
||||
|
||||
.. _Requests: https://python-requests.org
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ six==1.11.0
|
||||
snowballstemmer==1.2.1
|
||||
Sphinx==1.6.3
|
||||
sphinx-click==1.3.0
|
||||
sphinxcontrib-spelling==4.2.1
|
||||
sphinxcontrib-websupport==1.1.0
|
||||
urllib3==1.24.1
|
||||
virtualenv==16.1.0
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
appdir
|
||||
ascii
|
||||
asdf
|
||||
backport
|
||||
bashrc
|
||||
bundler
|
||||
canonicalized
|
||||
cmder
|
||||
Cmder
|
||||
codebase
|
||||
Conda
|
||||
CPython
|
||||
cygwin
|
||||
Deduplicate
|
||||
Devops
|
||||
eval
|
||||
filesystem
|
||||
Homebrew
|
||||
ini
|
||||
installable
|
||||
Integrations
|
||||
io
|
||||
js
|
||||
json
|
||||
Linuxbrew
|
||||
lockfile
|
||||
macOS
|
||||
Makefile
|
||||
manpage
|
||||
metadata
|
||||
mingw
|
||||
misconfiguration
|
||||
misconfigured
|
||||
msys
|
||||
natively
|
||||
npm
|
||||
parallelization
|
||||
parsers
|
||||
pathlib
|
||||
pexpect
|
||||
pipenv
|
||||
Pipenv
|
||||
Pipfile
|
||||
Pipfiles
|
||||
piptools
|
||||
powershell
|
||||
Powershell
|
||||
pre
|
||||
py
|
||||
pyenv
|
||||
pypi
|
||||
PyPI
|
||||
pythonfinder
|
||||
resolvers
|
||||
runtime
|
||||
runtimes
|
||||
sayers
|
||||
scandir
|
||||
sha
|
||||
stateful
|
||||
subdirectory
|
||||
subprocess
|
||||
subprocesses
|
||||
subshell
|
||||
supervisord
|
||||
tox
|
||||
Tox
|
||||
tracebacks
|
||||
triaging
|
||||
txt
|
||||
unicode
|
||||
uninstallation
|
||||
unnesting
|
||||
untrusted
|
||||
url
|
||||
urls
|
||||
UTF
|
||||
vcs
|
||||
vendored
|
||||
Vendored
|
||||
venv
|
||||
virtualenv
|
||||
virtualenvs
|
||||
Virtualenv
|
||||
Virtualenvs
|
||||
zsh
|
||||
zshrc
|
||||
+27045
-19976
File diff suppressed because it is too large
Load Diff
@@ -1 +0,0 @@
|
||||
Added documenation about variable expansion in ``Pipfile`` entries.
|
||||
@@ -1 +0,0 @@
|
||||
Raise `PipenvUsageError` when [[source]] does not contain url field.
|
||||
@@ -1 +0,0 @@
|
||||
Make conservative checks of known exceptions when subprocess returns output, so user won't see the whole traceback - just the error.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed a bug which caused editable package resolution to sometimes fail with an unhelpful setuptools-related error message.
|
||||
@@ -1,2 +0,0 @@
|
||||
Fixed an issue which caused errors due to reliance on the system utilities ``which`` and ``where`` which may not always exist on some systems.
|
||||
- Fixed a bug which caused periodic failures in python discovery when executables named ``python`` were not present on the target ``$PATH``.
|
||||
@@ -1 +0,0 @@
|
||||
Dependency resolution now writes hashes for local and remote files to the lockfile.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed a bug which prevented ``pipenv graph`` from correctly showing all dependencies when running from within ``pipenv shell``.
|
||||
@@ -1 +0,0 @@
|
||||
Consolidate all contributing docs in the rst file
|
||||
@@ -1 +0,0 @@
|
||||
Fixed resolution of direct-url dependencies in ``setup.py`` files to respect ``PEP-508`` style URL dependencies.
|
||||
@@ -1 +0,0 @@
|
||||
Added support for resolution of direct-url dependencies in ``setup.py`` files to respect ``PEP-508`` style URL dependencies.
|
||||
@@ -1 +0,0 @@
|
||||
Update the out-dated manual page.
|
||||
@@ -1 +0,0 @@
|
||||
Update pytest-pypi documentation not to be pytest-httpbin documentation.
|
||||
@@ -1,3 +0,0 @@
|
||||
Fixed a bug which caused failures in warning reporting when running pipenv inside a virtualenv under some circumstances.
|
||||
|
||||
- Fixed a bug with package discovery when running ``pipenv clean``.
|
||||
@@ -1,5 +0,0 @@
|
||||
Added full support for resolution of all dependency types including direct URLs, zip archives, tarballs, etc.
|
||||
|
||||
- Improved error handling and formatting.
|
||||
|
||||
- Introduced improved cross platform stream wrappers for better ``stdout`` and ``stderr`` consistency.
|
||||
@@ -1,34 +0,0 @@
|
||||
Updated vendored dependencies:
|
||||
|
||||
- **attrs**: ``18.2.0`` => ``19.1.0``
|
||||
- **certifi**: ``2018.10.15`` => ``2019.3.9``
|
||||
- **cached_property**: ``1.4.3`` => ``1.5.1``
|
||||
- **cerberus**: ``1.2.0`` => ``1.3.1``
|
||||
- **click-completion**: ``0.5.0`` => ``0.5.1``
|
||||
- **colorama**: ``0.3.9`` => ``0.4.1``
|
||||
- **distlib**: ``0.2.8`` => ``0.2.9``
|
||||
- **idna**: ``2.7`` => ``2.8``
|
||||
- **jinja2**: ``2.10.0`` => ``2.10.1``
|
||||
- **markupsafe**: ``1.0`` => ``1.1.1``
|
||||
- **orderedmultidict**: ``(new)`` => ``1.0``
|
||||
- **packaging**: ``18.0`` => ``19.0``
|
||||
- **parse**: ``1.9.0`` => ``1.12.0``
|
||||
- **pathlib2**: ``2.3.2`` => ``2.3.3``
|
||||
- **pep517**: ``(new)`` => ``0.5.0``
|
||||
- **pexpect**: ``4.6.0`` => ``4.7.0``
|
||||
- **pipdeptree**: ``0.13.0`` => ``0.13.2``
|
||||
- **pyparsing**: ``2.2.2`` => ``2.3.1``
|
||||
- **python-dotenv**: ``0.9.1`` => ``0.10.2``
|
||||
- **pythonfinder**: ``1.1.10`` => ``1.2.1``
|
||||
- **pytoml**: ``(new)`` => ``0.1.20``
|
||||
- **requests**: ``2.20.1`` => ``2.21.0``
|
||||
- **requirementslib**: ``1.3.3`` => ``1.5.0``
|
||||
- **scandir**: ``1.9.0`` => ``1.10.0``
|
||||
- **shellingham**: ``1.2.7`` => ``1.3.1``
|
||||
- **six**: ``1.11.0`` => ``1.12.0``
|
||||
- **tomlkit**: ``0.5.2`` => ``0.5.3``
|
||||
- **urllib3**: ``1.24`` => ``1.25.2``
|
||||
- **vistir**: ``0.3.0`` => ``0.4.1``
|
||||
- **yaspin**: ``0.14.0`` => ``0.14.3``
|
||||
|
||||
- Removed vendored dependency **cursor**.
|
||||
@@ -1 +0,0 @@
|
||||
Quote command arguments with carets (``^``) on Windows to work around unintended shell escapes.
|
||||
@@ -1 +0,0 @@
|
||||
Handle alternate names for UTF-8 encoding.
|
||||
@@ -1 +0,0 @@
|
||||
Abort pipenv before adding the non-exist package to Pipfile.
|
||||
@@ -1 +0,0 @@
|
||||
Don't normalize the package name user passes in.
|
||||
@@ -1 +0,0 @@
|
||||
Pipenv will now successfully recursively lock VCS sub-dependencies.
|
||||
@@ -1 +0,0 @@
|
||||
Fix a bug where custom virtualenv can not be activated with pipenv shell
|
||||
@@ -1 +0,0 @@
|
||||
Move CLI docs to its own page.
|
||||
@@ -1 +0,0 @@
|
||||
Added support for ``--verbose`` output to ``pipenv run``.
|
||||
@@ -1 +0,0 @@
|
||||
Fix a bug that ``--site-packages`` flag is not recognized.
|
||||
@@ -1 +0,0 @@
|
||||
Fix a bug where pipenv --clear is not working
|
||||
@@ -1 +0,0 @@
|
||||
The inline tables won't be rewritten now.
|
||||
@@ -1 +0,0 @@
|
||||
Pipenv will now discover and resolve the intrinsic dependencies of **all** VCS dependencies, whether they are editable or not, to prevent resolution conflicts.
|
||||
@@ -1 +0,0 @@
|
||||
Fix unhashable type error during ``$ pipenv install --selective-upgrade``
|
||||
@@ -1 +0,0 @@
|
||||
Do not touch Pipfile early and rely on it so that one can do ``pipenv sync`` without a Pipfile.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed a keyerror which could occur when locking VCS dependencies in some cases.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed a bug that ``ValidationError`` is thrown when some fields are missing in source section.
|
||||
@@ -1 +0,0 @@
|
||||
Improve the error message when one tries to initialize a Pipenv project under ``/``.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed the wrong order of old and new hashes in message.
|
||||
@@ -1 +0,0 @@
|
||||
Updated the index names in lock file when source name in Pipfile is changed.
|
||||
@@ -1 +0,0 @@
|
||||
Fixed an issue which caused ``pipenv install --help`` to show duplicate entries for ``--pre``.
|
||||
@@ -1 +0,0 @@
|
||||
Replace (non-existant) video on docs index.rst with equivalent gif.
|
||||
@@ -1 +0,0 @@
|
||||
Fix bug causing ``[SSL: CERTIFICATE_VERIFY_FAILED]`` when Pipfile ``[[source]]`` has verify_ssl=false and url with custom port.
|
||||
@@ -1 +0,0 @@
|
||||
Clarify wording in Basic Usage example on using double quotes to escape shell redirection
|
||||
@@ -1 +0,0 @@
|
||||
Ensure docs show navigation on small-screen devices
|
||||
@@ -1 +0,0 @@
|
||||
Fix ``sync --sequential`` ignoring ``pip install`` errors and logs.
|
||||
@@ -1 +0,0 @@
|
||||
Added a new environment variable, ``PIPENV_RESOLVE_VCS``, to toggle dependency resolution off for non-editable VCS, file, and URL based dependencies.
|
||||
@@ -1 +0,0 @@
|
||||
Fix the issue that lock file can't be created when ``PIPENV_PIPFILE`` is not under working directory.
|
||||
@@ -1 +0,0 @@
|
||||
Added the ability for Windows users to enable emojis by setting ``PIPENV_HIDE_EMOJIS=0``.
|
||||
@@ -1 +0,0 @@
|
||||
Removed unused vendored package shutilwhich
|
||||
@@ -1 +0,0 @@
|
||||
Added a link to the TOML Spec under General Recommendations & Version Control to clarify how Pipfiles should be written.
|
||||
@@ -1 +0,0 @@
|
||||
Removed unused vendored package blindspin
|
||||
@@ -1 +0,0 @@
|
||||
Use tablib instead of requests in tests to avoid failures when vendored
|
||||
@@ -1 +0,0 @@
|
||||
Pipenv will no longer inadvertently set ``editable=True`` on all vcs dependencies.
|
||||
@@ -1 +0,0 @@
|
||||
Allow overriding PIPENV_INSTALL_TIMEOUT environment variable (in seconds).
|
||||
@@ -1,2 +0,0 @@
|
||||
The ``--keep-outdated`` argument to ``pipenv install`` and ``pipenv lock`` will now drop specifier constraints when encountering editable dependencies.
|
||||
- In addition, ``--keep-outdated`` will retain specifiers that would otherwise be dropped from any entries that have not been updated.
|
||||
@@ -1 +0,0 @@
|
||||
Allow KeyboardInterrupt to cancel test suite checks for working internet and ssh
|
||||
@@ -1 +0,0 @@
|
||||
Cleaned up some conditional logic that would always evaluate ``True``.
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user