Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix compat.get_session #57

Merged
merged 3 commits into from
Mar 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ repos:
- id: black

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
rev: v2.5.0
hooks:
- id: flake8

- repo: https://github.com/asottile/seed-isort-config
rev: v1.9.4
rev: v2.1.0
hooks:
- id: seed-isort-config

Expand Down
81 changes: 66 additions & 15 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,76 @@
language: python
sudo: false
cache: pip
dist: trusty
dist: bionic


matrix:
fast_finish: true
allow_failures:
- python: "3.4"
python: "3.5"

install:
- "python -m pip install ${PIP}"
- "python -m pip install ${PIP} setuptools wheel"
- "python -m pip install pytest pytest-xdist pytest-cov pytest-timeout"
- "python -m pip install -e .[tests]"
script:
- "python -m pytest -v -n 8 tests/"

jobs:
include:
- &test-pip19
- &test-pip20
stage: test-pip20
python: "3.6"
env: PIP="pip==20.0.2"
- <<: *test-pip20
python: "3.8"
- <<: *test-pip20
python: "3.7"
- <<: *test-pip20
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip20
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip20
python: "2.7"
- &test-pip193
stage: test-pip193
python: "3.6"
env: PIP="pip==19.3.1"
- <<: *test-pip193
python: "3.8"
- <<: *test-pip193
python: "3.7"
- <<: *test-pip193
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip193
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip193
python: "2.7"
- &test-pip19
stage: test-pip19
python: "3.6"
env: PIP="pip==19.0.3"
- <<: *test-pip19
python: "3.8"
- <<: *test-pip19
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pip19
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip19
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip19
python: "2.7"
- &test-pip181
Expand All @@ -38,12 +79,14 @@ jobs:
env: PIP="pip==18.1"
- <<: *test-pip181
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pip181
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip181
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip181
python: "2.7"
- &test-pipmaster
Expand All @@ -56,12 +99,14 @@ jobs:
- "python -m pip install -e .[tests] --no-use-pep517"
- <<: *test-pipmaster
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pipmaster
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pipmaster
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pipmaster
python: "2.7"
- &test-pip9
Expand All @@ -70,12 +115,14 @@ jobs:
env: PIP="pip==9.0.3"
- <<: *test-pip9
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pip9
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip9
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip9
python: "2.7"
- &test-pip10
Expand All @@ -84,12 +131,14 @@ jobs:
env: PIP="pip==10.0.1"
- <<: *test-pip10
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pip10
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip10
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip10
python: "2.7"
- &test-pip180
Expand All @@ -98,12 +147,14 @@ jobs:
env: PIP="pip==18.0"
- <<: *test-pip180
python: "3.7"
dist: xenial
sudo: required
- <<: *test-pip180
python: "3.5"
dist: xenial
sudo: required
- <<: *test-pip180
python: "3.4"
dist: xenial
sudo: required
- <<: *test-pip180
python: "2.7"
- stage: packaging
Expand Down
75 changes: 64 additions & 11 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,51 +5,96 @@ environment:
RUN_INTEGRATION_TESTS: "True"
- PYTHON: "C:\\Python36-x64"
RUN_INTEGRATION_TESTS: "True"
- PYTHON: "C:\\Python37-x64"
RUN_INTEGRATION_TESTS: "True"
- PYTHON: "C:\\Python38-x64"
RUN_INTEGRATION_TESTS: "True"
# Unit tests only.
- PYTHON: "C:\\Python27-x64"
- PYTHON: "C:\\Python34-x64"
- PYTHON: "C:\\Python35-x64"
- PYTHON: "C:\\Python36-x64"
- PYTHON: "C:\\Python37-x64"
- PYTHON: "C:\\Python38-x64"
- PYTHON: "C:\\Python27-x64"
PIP: "20.0.2"
- PYTHON: "C:\\Python35-x64"
PIP: "20.0.2"
- PYTHON: "C:\\Python36-x64"
PIP: "20.0.2"
- PYTHON: "C:\\Python37-x64"
PIP: "20.0.2"
- PYTHON: "C:\\Python38-x64"
PIP: "20.0.2"
- PYTHON: "C:\\Python27-x64"
PIP: "19.3.1"
- PYTHON: "C:\\Python35-x64"
PIP: "19.3.1"
- PYTHON: "C:\\Python36-x64"
PIP: "19.3.1"
- PYTHON: "C:\\Python37-x64"
PIP: "19.3.1"
- PYTHON: "C:\\Python38-x64"
PIP: "19.3.1"
- PYTHON: "C:\\Python27-x64"
PIP: "19.2.3"
- PYTHON: "C:\\Python35-x64"
PIP: "19.2.3"
- PYTHON: "C:\\Python36-x64"
PIP: "19.2.3"
- PYTHON: "C:\\Python37-x64"
PIP: "19.2.3"
- PYTHON: "C:\\Python38-x64"
PIP: "19.2.3"
- PYTHON: "C:\\Python27-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python34-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python35-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python36-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python37-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python38-x64"
PIP: "19.0.3"
- PYTHON: "C:\\Python27-x64"
PIP: "18.1"
- PYTHON: "C:\\Python34-x64"
PIP: "18.1"
- PYTHON: "C:\\Python35-x64"
PIP: "18.1"
- PYTHON: "C:\\Python36-x64"
PIP: "18.1"
- PYTHON: "C:\\Python37-x64"
PIP: "18.1"
- PYTHON: "C:\\Python38-x64"
PIP: "18.1"
- PYTHON: "C:\\Python27-x64"
PIP: "18.0"
- PYTHON: "C:\\Python34-x64"
PIP: "18.0"
- PYTHON: "C:\\Python35-x64"
PIP: "18.0"
- PYTHON: "C:\\Python36-x64"
PIP: "18.0"
- PYTHON: "C:\\Python37-x64"
PIP: "18.0"
- PYTHON: "C:\\Python38-x64"
PIP: "18.0"
- PYTHON: "C:\\Python27-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python34-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python35-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python36-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python37-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python38-x64"
PIP: "10.0.1"
- PYTHON: "C:\\Python27-x64"
PIP: "9.0.3"
- PYTHON: "C:\\Python34-x64"
PIP: "9.0.3"
- PYTHON: "C:\\Python35-x64"
PIP: "9.0.3"
- PYTHON: "C:\\Python36-x64"
PIP: "9.0.3"
- PYTHON: "C:\\Python37-x64"
PIP: "9.0.3"
- PYTHON: "C:\\Python38-x64"
PIP: "9.0.3"

install:
- ps: |
Expand Down Expand Up @@ -80,6 +125,11 @@ install:
If ($LastExitCode -ne 0) {
exit $LastExitCode
}
if ( $env:PYTHON -eq "3.4" ) {
Invoke-Expression "$py_exe -m pip install --upgrade --upgrade-strategy=eager pip==19.1 setuptools wheel"
} else {
Invoke-Expression "$py_exe -m pip install --upgrade --upgrade-strategy=eager pip setuptools wheel"
}

Invoke-Expression "$py_exe -m pip install --upgrade setuptools pytest pytest-xdist pytest-timeout"
If ($LastExitCode -ne 0) {
Expand All @@ -93,6 +143,9 @@ install:

if ( $env:PIP ) {
Invoke-Expression "$py_exe -m pip install -e .[tests]"
If ($LastExitCode -ne 0) {
Invoke-Expression "$py_exe -m pip install -e .[tests] --no-use-pep517"
}
}
else {
Invoke-Expression "$py_exe -m pip install -e .[tests] --no-use-pep517"
Expand Down
1 change: 1 addition & 0 deletions news/56.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixed incorrect session creation via ``pip_shims.compat.get_session`` which inadvertently passed a tuple to pip when building a session instance.
2 changes: 2 additions & 0 deletions news/58.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Added ``wheel_cache`` context manager helper for managing global context when creating wheel wheel_cache instances.

3 changes: 3 additions & 0 deletions news/59.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Fixed resolution failures due to ``Resolver.resolve`` signature updates in ``pip@master``:
- Automatically check for and pass ``check_supports_wheel`` argument to `Resolver.resolve()` when expected
- Check whether ``Resolver.resolve()`` expects a ``RequirementSet`` or ``List[InstallRequirement]`` and pass the appropriate input
1 change: 1 addition & 0 deletions news/60.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixed requirement build failures due to new ``autodelete: bool`` required argument in ``InstallRequirement.ensure_build_location``.
1 change: 1 addition & 0 deletions news/61.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Updated ``Resolver`` import path to point at new location (``legacy_resolve`` -> ``resolution.legacy.resolver``).
1 change: 1 addition & 0 deletions news/62.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixed ``AttributeError`` caused by failed ``RequirementSet.cleanup()`` calls after ``Resolver.resolve()`` which is no longer valid in ``pip>=20.1``.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ tests =
pytest-xdist
pytest-cov
twine
readme-renderer[md]
readme-renderer[md];python_version<"3.8"
dev =
pre-commit
mypy;python_version>="3.5"
Expand Down
Loading