Skip to content

Commit e48d149

Browse files
Bump mypy from 0.982 to 0.990 (#621)
* Bump mypy from 0.982 to 0.990 Bumps [mypy](https://github.com/python/mypy) from 0.982 to 0.990. - [Release notes](https://github.com/python/mypy/releases) - [Commits](python/mypy@v0.982...v0.990) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * mypy 0.990 inspired fixs + 1 ignore Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Michael R. Crusoe <[email protected]>
1 parent 447b2bd commit e48d149

File tree

13 files changed

+25
-28
lines changed

13 files changed

+25
-28
lines changed

.circleci/config.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ jobs:
1717
CIBW_MANYLINUX_AARCH64_IMAGE: "<< parameters.many_image >>"
1818
CIBW_MUSLLINUX_AARCH64_IMAGE: quay.io/pypa/musllinux_1_1_aarch64
1919
CIBW_BUILD: "<< parameters.build >>"
20-
CIBW_SKIP: "cp36-* pp*"
2120

2221
steps:
2322
- checkout

.github/workflows/ci-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
step: [lintreadme, pydocstyle]
7575

7676
env:
77-
py-semver: "3.10"
77+
py-semver: "3.11"
7878
TOXENV: ${{ format('py310-{0}', matrix.step) }}
7979

8080
steps:

.github/workflows/wheels.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,25 +20,25 @@ jobs:
2020
with:
2121
pre-build-command: source .github/workflows/wheel-prep.sh
2222
build-requirements: -rrequirements.txt -rmypy-requirements.txt
23-
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310'
23+
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310 cp311-cp311'
2424
- name: Build manylinux2014 x86_64 Python wheels
2525
uses: RalfG/[email protected]_x86_64
2626
with:
2727
pre-build-command: source .github/workflows/wheel-prep.sh
2828
build-requirements: -rrequirements.txt -rmypy-requirements.txt
29-
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310'
29+
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310 cp311-cp311'
3030
- name: Build manylinux_2_24 x86_64 Python wheels
3131
uses: RalfG/[email protected]_2_24_x86_64
3232
with:
3333
pre-build-command: source .github/workflows/wheel-prep.sh
3434
build-requirements: -rrequirements.txt -rmypy-requirements.txt
35-
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310'
35+
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310 cp311-cp311'
3636
- name: Build manylinux_2_28 x86_64 Python wheels
3737
uses: RalfG/[email protected]_2_28_x86_64
3838
with:
3939
pre-build-command: source .github/workflows/wheel-prep.sh
4040
build-requirements: -rrequirements.txt -rmypy-requirements.txt
41-
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310'
41+
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310 cp311-cp311'
4242
- name: Move audited wheels to new directory
4343
run: mkdir audited_wheels && cp dist/*-manylinux*.whl dist/*-musllinux*.whl audited_wheels/
4444
- name: Publish wheels to PyPI

Makefile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ EXTRAS=[pycodegen]
2828
# `[[` conditional expressions.
2929
PYSOURCES=$(wildcard ${MODULE}/**.py ${MODULE}/avro/*.py ${MODULE}/tests/*.py) setup.py
3030
DEVPKGS=diff_cover black pylint pep257 pydocstyle flake8 tox tox-pyenv \
31-
isort wheel autoflake flake8-bugbear pyupgrade bandit \
31+
isort wheel autoflake flake8-bugbear pyupgrade bandit build\
3232
-rtest-requirements.txt -rmypy-requirements.txt
3333
COVBASE=coverage run --append
3434

@@ -66,7 +66,7 @@ dev: install-dep
6666
dist: dist/${MODULE}-$(VERSION).tar.gz
6767

6868
dist/${MODULE}-$(VERSION).tar.gz: $(SOURCES)
69-
python setup.py sdist bdist_wheel
69+
python -m build
7070

7171
## docs : make the docs
7272
docs: FORCE
@@ -199,7 +199,8 @@ release:
199199
export SETUPTOOLS_SCM_PRETEND_VERSION=${VERSION} && \
200200
./release-test.sh && \
201201
. testenv2/bin/activate && \
202-
python testenv2/src/${PACKAGE}/setup.py sdist bdist_wheel && \
202+
pip install build && \
203+
python -m build testenv2/src/${PACKAGE} && \
203204
pip install twine && \
204205
twine upload testenv2/src/${PACKAGE}/dist/* && \
205206
git tag ${VERSION} && git push --tags

mypy-requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
mypy==0.982
1+
mypy==0.990
22
black>=19.10b0
33
types-pkg_resources
44
types-requests

mypy-stubs/rdflib/namespace/__init__.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ __all__ = [
3333

3434
class Namespace(str):
3535
@property
36-
def title(self) -> URIRef: ...
36+
def title(self) -> URIRef: ... # type: ignore[override]
3737
def term(self, name: Any) -> URIRef: ...
3838
def __getitem__(self, key: Any) -> URIRef: ...
3939
def __getattr__(self, name: str) -> URIRef: ...

pyproject.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["setuptools>=45", "setuptools_scm[toml]>=6.2", "mypy==0.961", "black>=19.10b0", "types-pkg_resources", "types-requests", "types-dataclasses", "ruamel.yaml>= 0.12.4, != 0.16.6, < 0.18", "types-setuptools"]
2+
requires = ["setuptools>=45", "setuptools_scm[toml]>=6.2", "mypy==0.990;python_version>'3.6'", "black>=19.10b0", "types-pkg_resources", "types-requests", "types-dataclasses", "ruamel.yaml>= 0.12.4, != 0.16.6, < 0.18", "types-setuptools"]
33
build-backend = "setuptools.build_meta"
44

55
[tool.setuptools_scm]
@@ -10,7 +10,7 @@ before-build = "python -m pip install -r requirements.txt -r mypy-requirements.t
1010
test-command = "python -m pytest -n 2 --junitxml=/output/test-results/junit_$(python -V | awk '{print $2}')_${AUDITWHEEL_PLAT}.xml --pyargs schema_salad"
1111
test-requires = "-r test-requirements.txt"
1212
test-extras = "pycodegen"
13-
skip = "pp* cp311-*"
14-
# ^ skip building wheels on PyPy (any version)
15-
# and CPython 3.11 (mypyc doesn't support Python 3.11)
13+
skip = "pp* cp36-*"
14+
# ^ skip building wheels on PyPy (any version)
15+
# ^ skip building wheels on Python 3.6 (we now need mypy 0.990+ which doesn't support Python 3.6)
1616
build-verbosity = "1"

release-test.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ rm -f lib/python-wheels/setuptools* \
6363
# The following can fail if you haven't pushed your commits to ${repo}
6464
pip install -e "git+${repo}@${HEAD}#egg=${package}${extras}"
6565
pushd src/${package}
66-
pip install -rtest-requirements.txt
66+
pip install -rtest-requirements.txt build
6767
make dist
6868
make test
6969
cp dist/${package}*tar.gz ../../../testenv3/
@@ -84,7 +84,7 @@ rm -f lib/python-wheels/setuptools* \
8484
&& pip install --force-reinstall -U pip==${pipver} \
8585
&& pip install setuptools==${setuptoolsver} wheel
8686
package_tar=$(find . -name "${package}*tar.gz")
87-
pip install "-r${DIR}/test-requirements.txt"
87+
pip install "-r${DIR}/test-requirements.txt" build
8888
pip install "${package_tar}${extras}"
8989
mkdir out
9090
tar --extract --directory=out -z -f ${package}*.tar.gz

schema_salad/makedoc.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -782,9 +782,7 @@ def makedoc(
782782
redirect[r.split("=")[0]] = r.split("=")[1]
783783
renderlist = only or []
784784
if hasattr(stdout, "buffer") and getattr(stdout, "encoding", None) != "UTF-8":
785-
wrapped_stdout: IO[Any] = TextIOWrapper(
786-
stdout.buffer, encoding="utf-8" # type: ignore[attr-defined]
787-
)
785+
wrapped_stdout: IO[Any] = TextIOWrapper(stdout.buffer, encoding="utf-8")
788786
else:
789787
wrapped_stdout = stdout
790788
avrold_doc(

schema_salad/tests/test_dotnet_codegen.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def test_cwl_gen(tmp_path: Path) -> None:
2222

2323
dotnet_codegen(cwl_file_uri, target_dir, examples=examples_dir)
2424
solution_path = target_dir / "Solution.sln"
25-
assert solution_path.exists
25+
assert solution_path.exists()
2626
tests_dir = target_dir / "Test" / "src"
2727
assert tests_dir.exists()
2828
with open(tests_dir / "ExampleTests.cs") as f:
@@ -54,7 +54,7 @@ def test_class_field(tmp_path: Path) -> None:
5454
dotnet_codegen(schema_path, target_dir)
5555

5656
solution_path = target_dir / "Solution.sln"
57-
assert solution_path.exists
57+
assert solution_path.exists()
5858

5959
tests_dir = target_dir / "Test"
6060
assert tests_dir.exists()

0 commit comments

Comments
 (0)