Skip to content

Commit b237d48

Browse files
committed
Annotate ReasonCode.names to MappingProxyType | dict
1 parent 7a3d161 commit b237d48

5 files changed

Lines changed: 10 additions & 9 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: build
22
on:
33
pull_request:
4-
branches: [master]
4+
branches: [master, Fix_mypy_error_in_workflow]
55
push:
6-
branches: [master]
6+
branches: [master, Fix_mypy_error_in_workflow]
77
jobs:
88
build:
99
runs-on: ubuntu-latest

.github/workflows/lint-python.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: lint_python
22
on:
33
pull_request:
4-
branches: [master]
4+
branches: [master, Fix_mypy_error_in_workflow]
55
push:
6-
branches: [master]
6+
branches: [master, Fix_mypy_error_in_workflow]
77
jobs:
88
lint_python:
99
runs-on: ubuntu-latest

.github/workflows/precommit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
name: pre-commit
55
on:
66
pull_request:
7-
branches: [master]
7+
branches: [master, Fix_mypy_error_in_workflow]
88
push:
9-
branches: [master]
9+
branches: [master, Fix_mypy_error_in_workflow]
1010
jobs:
1111
pre-commit:
1212
runs-on: ubuntu-latest

.github/workflows/tox.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: tox
22
on:
33
pull_request:
4-
branches: [master]
4+
branches: [master, Fix_mypy_error_in_workflow]
55
push:
6-
branches: [master]
6+
branches: [master, Fix_mypy_error_in_workflow]
77
jobs:
88
tox:
99
strategy:

src/paho/mqtt/reasoncodes.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
# Contributors:
1414
# Ian Craggs - initial implementation and/or documentation
1515
# *******************************************************************
16+
from __future__ import annotations
1617

1718
import functools
1819
import warnings
@@ -31,7 +32,7 @@ class ReasonCode:
3132
3233
"""
3334

34-
names = MappingProxyType(
35+
names: MappingProxyType | dict = MappingProxyType(
3536
{
3637
0: {
3738
"Success": [

0 commit comments

Comments
 (0)