Skip to content

Commit 3294748

Browse files
authored
drop 3.7, add mypy test, bump reqs, etc (#189)
Split out from #188 with a `--patch` checkout. This does destroy the commit history, so I might need to rewrite the history in #188 to avoid conflicts. * Drops python3.7 support. It still works afaik, but is a pain to test in CI. * Adds loose mypy run to Makefile & CI * Adds some type annotations * ~~Adds 3.13-dev test run. It currently fails, but will pass once trio and cffi push new releases.~~ * Adds blurb to readme on status of the project. * Bump package versions in requirements-dev.txt and requirements-dev-full.txt * Adds small tests to slightly bump code coverage
1 parent 6a004bb commit 3294748

File tree

10 files changed

+184
-118
lines changed

10 files changed

+184
-118
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
os: [ubuntu-latest]
1515
# latest pylint/astroid doesn't support 3.7
1616
# python3.7 is covered in build_and_test_old_deps
17-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12-dev']
17+
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
1818

1919
steps:
2020
- uses: actions/checkout@v3
@@ -27,13 +27,14 @@ jobs:
2727
- run: pip install . -r requirements-dev-full.txt
2828
- run: make test
2929
- run: make lint
30+
- run: make typecheck
3031

3132
build_and_test_old_deps:
3233
runs-on: ${{ matrix.os }}
3334
strategy:
3435
matrix:
3536
os: [ubuntu-latest]
36-
python-version: ['3.7']
37+
python-version: ['3.8']
3738

3839
steps:
3940
- uses: actions/checkout@v3
@@ -73,7 +74,7 @@ jobs:
7374
strategy:
7475
matrix:
7576
os: [ubuntu-latest]
76-
python-version: ['3.12-dev']
77+
python-version: ['3.12']
7778
steps:
7879
- uses: actions/checkout@v3
7980
- name: Setup Python

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,14 @@ docs:
88
$(MAKE) -C docs html
99

1010
test:
11-
$(PYTHON) -m pytest --cov=trio_websocket --no-cov-on-fail
11+
$(PYTHON) -m pytest --cov=trio_websocket --cov-report=term-missing --no-cov-on-fail
1212

1313
lint:
1414
$(PYTHON) -m pylint trio_websocket/ tests/ autobahn/ examples/
1515

16+
typecheck:
17+
$(PYTHON) -m mypy --explicit-package-bases trio_websocket tests autobahn examples
18+
1619
publish:
1720
rm -fr build dist .egg trio_websocket.egg-info
1821
! grep -q dev trio_websocket/_version.py

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ available here](https://trio-websocket.readthedocs.io).
1717
![Python Versions](https://img.shields.io/pypi/pyversions/trio-websocket.svg?style=flat-square)
1818
[![Build Status](https://img.shields.io/github/actions/workflow/status/python-trio/trio-websocket/ci.yml)](https://github.com/python-trio/trio-websocket/actions/workflows/ci.yml)
1919
[![Read the Docs](https://img.shields.io/readthedocs/trio-websocket.svg)](https://trio-websocket.readthedocs.io)
20+
[![Join chatroom](https://img.shields.io/badge/chat-join%20now-blue.svg)](https://gitter.im/python-trio/general)
21+
22+
## Status
23+
**This project is on life-support maintenance.** If you're interested in helping to maintain and contribute, please reach out on [Gitter](https://gitter.im/python-trio/general) or contribute in issues and pull requests.
2024

2125
## Alternatives
2226

requirements-dev-full.txt

Lines changed: 86 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -6,155 +6,175 @@
66
#
77
alabaster==0.7.13
88
# via sphinx
9-
astroid==3.0.0
9+
astroid==3.2.2
1010
# via pylint
11-
async-generator==1.10
12-
# via trio
13-
attrs==22.2.0
11+
attrs==23.2.0
1412
# via
1513
# -r requirements-dev.in
1614
# outcome
1715
# trio
18-
babel==2.12.1
16+
babel==2.15.0
1917
# via sphinx
20-
bleach==6.0.0
21-
# via readme-renderer
22-
build==0.10.0
18+
backports-tarfile==1.2.0
19+
# via jaraco-context
20+
build==1.2.1
2321
# via pip-tools
24-
certifi==2022.12.7
22+
certifi==2024.6.2
2523
# via requests
26-
cffi==1.15.1
24+
cffi==1.16.0
2725
# via cryptography
28-
charset-normalizer==3.1.0
26+
charset-normalizer==3.3.2
2927
# via requests
30-
click==8.1.3
28+
click==8.1.7
3129
# via pip-tools
32-
coverage[toml]==7.2.1
30+
coverage[toml]==7.5.3
3331
# via pytest-cov
34-
cryptography==39.0.2
35-
# via trustme
36-
dill==0.3.7
32+
cryptography==42.0.8
33+
# via
34+
# secretstorage
35+
# trustme
36+
dill==0.3.8
3737
# via pylint
38-
docutils==0.18.1
38+
docutils==0.20.1
3939
# via
4040
# readme-renderer
4141
# sphinx
4242
# sphinx-rtd-theme
43-
exceptiongroup==1.1.3 ; python_version < "3.11"
43+
exceptiongroup==1.2.1 ; python_version < "3.11"
4444
# via
4545
# pytest
4646
# trio
4747
# trio-websocket (setup.py)
4848
h11==0.14.0
4949
# via wsproto
50-
idna==3.4
50+
idna==3.7
5151
# via
5252
# requests
5353
# trio
5454
# trustme
5555
imagesize==1.4.1
5656
# via sphinx
57-
importlib-metadata==6.0.0
57+
importlib-metadata==7.1.0
5858
# via
59+
# build
5960
# keyring
6061
# sphinx
6162
# twine
62-
importlib-resources==6.1.0
63+
importlib-resources==6.4.0
6364
# via keyring
6465
iniconfig==2.0.0
6566
# via pytest
66-
isort==5.11.5
67+
isort==5.13.2
6768
# via pylint
68-
jaraco-classes==3.2.3
69+
jaraco-classes==3.4.0
6970
# via keyring
70-
jinja2==3.1.2
71+
jaraco-context==5.3.0
72+
# via keyring
73+
jaraco-functools==4.0.1
74+
# via keyring
75+
jeepney==0.8.0
76+
# via
77+
# keyring
78+
# secretstorage
79+
jinja2==3.1.4
7180
# via sphinx
72-
keyring==23.13.1
81+
keyring==25.2.1
7382
# via twine
74-
markdown-it-py==2.2.0
83+
markdown-it-py==3.0.0
7584
# via rich
76-
markupsafe==2.1.2
85+
markupsafe==2.1.5
7786
# via jinja2
7887
mccabe==0.7.0
7988
# via pylint
8089
mdurl==0.1.2
8190
# via markdown-it-py
82-
more-itertools==9.1.0
83-
# via jaraco-classes
84-
outcome==1.2.0
91+
more-itertools==10.3.0
92+
# via
93+
# jaraco-classes
94+
# jaraco-functools
95+
mypy==1.10.0
96+
# via -r requirements-extras.in
97+
mypy-extensions==1.0.0
98+
# via mypy
99+
nh3==0.2.17
100+
# via readme-renderer
101+
outcome==1.3.0.post0
85102
# via
86103
# pytest-trio
87104
# trio
88-
packaging==23.0
105+
packaging==24.1
89106
# via
90107
# build
91108
# pytest
92109
# sphinx
93-
pip-tools==6.14.0
110+
pip-tools==7.4.1
94111
# via -r requirements-dev.in
95-
pkginfo==1.9.6
112+
pkginfo==1.11.1
96113
# via twine
97-
platformdirs==3.1.1
114+
platformdirs==4.2.2
98115
# via pylint
99-
pluggy==1.0.0
116+
pluggy==1.5.0
100117
# via pytest
101-
pycparser==2.21
118+
pycparser==2.22
102119
# via cffi
103-
pygments==2.14.0
120+
pygments==2.18.0
104121
# via
105122
# readme-renderer
106123
# rich
107124
# sphinx
108-
pylint==3.0.0a7
125+
pylint==3.2.3
109126
# via -r requirements-extras.in
110-
pyproject-hooks==1.0.0
111-
# via build
112-
pytest==7.4.2
127+
pyproject-hooks==1.1.0
128+
# via
129+
# build
130+
# pip-tools
131+
pytest==8.2.2
113132
# via
114133
# -r requirements-dev.in
115134
# pytest-cov
116135
# pytest-trio
117-
pytest-cov==4.0.0
136+
pytest-cov==5.0.0
118137
# via -r requirements-dev.in
119138
pytest-trio==0.8.0
120139
# via -r requirements-dev.in
121-
pytz==2023.3.post1
140+
pytz==2024.1
122141
# via babel
123-
readme-renderer==37.3
142+
readme-renderer==43.0
124143
# via twine
125-
requests==2.28.2
144+
requests==2.32.3
126145
# via
127146
# requests-toolbelt
128147
# sphinx
129148
# twine
130-
requests-toolbelt==0.10.1
149+
requests-toolbelt==1.0.0
131150
# via twine
132151
rfc3986==2.0.0
133152
# via twine
134-
rich==13.3.2
153+
rich==13.7.1
135154
# via twine
136-
six==1.16.0
137-
# via bleach
138-
sniffio==1.3.0
155+
secretstorage==3.3.3
156+
# via keyring
157+
sniffio==1.3.1
139158
# via trio
140159
snowballstemmer==2.2.0
141160
# via sphinx
142161
sortedcontainers==2.4.0
143162
# via trio
144-
sphinx==5.3.0
163+
sphinx==7.1.2
145164
# via
146165
# -r requirements-extras.in
147166
# sphinx-rtd-theme
167+
# sphinxcontrib-jquery
148168
# sphinxcontrib-trio
149-
sphinx-rtd-theme==1.2.0
169+
sphinx-rtd-theme==2.0.0
150170
# via -r requirements-extras.in
151-
sphinxcontrib-applehelp==1.0.2
171+
sphinxcontrib-applehelp==1.0.4
152172
# via sphinx
153173
sphinxcontrib-devhelp==1.0.2
154174
# via sphinx
155-
sphinxcontrib-htmlhelp==2.0.0
175+
sphinxcontrib-htmlhelp==2.0.1
156176
# via sphinx
157-
sphinxcontrib-jquery==2.0.0
177+
sphinxcontrib-jquery==4.1
158178
# via sphinx-rtd-theme
159179
sphinxcontrib-jsmath==1.0.1
160180
# via sphinx
@@ -168,36 +188,36 @@ tomli==2.0.1
168188
# via
169189
# build
170190
# coverage
191+
# mypy
171192
# pip-tools
172193
# pylint
173-
# pyproject-hooks
174194
# pytest
175-
tomlkit==0.11.6
195+
tomlkit==0.12.5
176196
# via pylint
177-
trio==0.22.0
197+
trio==0.24.0
178198
# via
199+
# -r requirements-dev.in
179200
# pytest-trio
180201
# trio-websocket (setup.py)
181-
trustme==0.9.0
202+
trustme==1.1.0
182203
# via -r requirements-dev.in
183-
twine==4.0.2
204+
twine==5.1.0
184205
# via -r requirements-extras.in
185-
typing-extensions==4.8.0
206+
typing-extensions==4.12.2
186207
# via
187208
# astroid
209+
# mypy
188210
# pylint
189211
# rich
190-
urllib3==1.26.15
212+
urllib3==2.2.1
191213
# via
192214
# requests
193215
# twine
194-
webencodings==0.5.1
195-
# via bleach
196-
wheel==0.38.4
216+
wheel==0.43.0
197217
# via pip-tools
198218
wsproto==1.2.0
199219
# via trio-websocket (setup.py)
200-
zipp==3.15.0
220+
zipp==3.19.2
201221
# via
202222
# importlib-metadata
203223
# importlib-resources

requirements-dev.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ pip-tools>=5.5.0
44
pytest>=4.6
55
pytest-cov
66
pytest-trio>=0.5.0
7+
trio<0.25
78
trustme

0 commit comments

Comments
 (0)