Skip to content

Commit ba573e2

Browse files
[3.8] Fix CI (#7143) (#7200)
1 parent 9cde3b4 commit ba573e2

File tree

6 files changed

+21
-18
lines changed

6 files changed

+21
-18
lines changed

.github/workflows/ci.yml

+12-12
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,9 @@ jobs:
5959
- name: Run linters
6060
run: |
6161
make mypy
62-
- name: Install libenchant-dev
62+
- name: Install libenchant
6363
run: |
64-
sudo apt install libenchant-dev
64+
sudo apt install libenchant-2-dev
6565
- name: Install spell checker
6666
run: |
6767
pip install -r requirements/doc-spelling.txt -c requirements/constraints.txt
@@ -119,36 +119,36 @@ jobs:
119119
matrix:
120120
pyver: [3.6, 3.7, 3.8, 3.9, '3.10']
121121
no-extensions: ['', 'Y']
122-
os: [ubuntu, macos, windows]
122+
os: [ubuntu-20.04, macos-latest, windows-latest]
123123
exclude:
124-
- os: macos
124+
- os: macos-latest
125125
no-extensions: 'Y'
126-
- os: macos
126+
- os: macos-latest
127127
pyver: 3.7
128-
- os: macos
128+
- os: macos-latest
129129
pyver: 3.8
130-
- os: windows
130+
- os: windows-latest
131131
no-extensions: 'Y'
132132
experimental: [false]
133133
include:
134134
- pyver: pypy-3.8
135135
no-extensions: 'Y'
136-
os: ubuntu
136+
os: ubuntu-latest
137137
experimental: false
138-
- os: macos
138+
- os: macos-latest
139139
pyver: "3.11.0-alpha - 3.11.0"
140140
experimental: true
141141
no-extensions: 'Y'
142-
- os: ubuntu
142+
- os: ubuntu-latest
143143
pyver: "3.11.0-alpha - 3.11.0"
144144
experimental: false
145145
no-extensions: 'Y'
146-
- os: windows
146+
- os: windows-latest
147147
pyver: "3.11.0-alpha - 3.11.0"
148148
experimental: true
149149
no-extensions: 'Y'
150150
fail-fast: true
151-
runs-on: ${{ matrix.os }}-latest
151+
runs-on: ${{ matrix.os }}
152152
continue-on-error: ${{ matrix.experimental }}
153153
steps:
154154
- name: Checkout

.mypy.ini

+2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
[mypy]
2+
# Only for 3.8 branch which is already EOL
3+
ignore_errors = True
24
files = aiohttp, examples
35
check_untyped_defs = True
46
follow_imports_for_stubs = True

aiohttp/helpers.py

+1
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
PY_37 = sys.version_info >= (3, 7)
6363
PY_38 = sys.version_info >= (3, 8)
6464
PY_310 = sys.version_info >= (3, 10)
65+
PY_311 = sys.version_info >= (3, 11)
6566

6667
if sys.version_info < (3, 7):
6768
import idna_ssl

tests/test_client_request.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
Fingerprint,
2020
_merge_ssl_params,
2121
)
22-
from aiohttp.helpers import PY_310
22+
from aiohttp.helpers import PY_311
2323
from aiohttp.test_utils import make_mocked_coro
2424

2525

@@ -276,7 +276,7 @@ def test_host_header_ipv6_with_port(make_request) -> None:
276276

277277

278278
@pytest.mark.xfail(
279-
PY_310,
279+
PY_311,
280280
reason="No idea why ClientRequest() is constructed out of loop but "
281281
"it calls `asyncio.get_event_loop()`",
282282
raises=DeprecationWarning,

tests/test_streams.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
from re_assert import Matches
1313

1414
from aiohttp import streams
15-
from aiohttp.helpers import PY_310
15+
from aiohttp.helpers import PY_311
1616

1717
DATA = b"line1\nline2\nline3\n"
1818

@@ -84,7 +84,7 @@ async def test_create_waiter(self) -> None:
8484
await stream._wait("test")
8585

8686
@pytest.mark.xfail(
87-
PY_310,
87+
PY_311,
8888
reason="No idea why ClientRequest() is constructed out of loop but "
8989
"it calls `asyncio.get_event_loop()`",
9090
raises=DeprecationWarning,

tests/test_web_app.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
from aiohttp import log, web
88
from aiohttp.abc import AbstractAccessLogger, AbstractRouter
9-
from aiohttp.helpers import DEBUG, PY_36, PY_310
9+
from aiohttp.helpers import DEBUG, PY_36, PY_311
1010
from aiohttp.test_utils import make_mocked_coro
1111
from aiohttp.typedefs import Handler
1212

@@ -40,7 +40,7 @@ async def test_set_loop() -> None:
4040

4141

4242
@pytest.mark.xfail(
43-
PY_310,
43+
PY_311,
4444
reason="No idea why _set_loop() is constructed out of loop "
4545
"but it calls `asyncio.get_event_loop()`",
4646
raises=DeprecationWarning,

0 commit comments

Comments
 (0)