Skip to content

Commit 9161f30

Browse files
Mic92mergify[bot]
authored andcommitted
add types
1 parent 9ccd8e0 commit 9161f30

File tree

7 files changed

+629
-495
lines changed

7 files changed

+629
-495
lines changed

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
python312
2121
pypy3
2222
twine
23+
mypy
2324
];
2425
shellHook = ''
2526
# breaks python36/python37

mpd/__init__.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,12 @@
2828
from mpd.base import ProtocolError
2929
from mpd.base import VERSION
3030

31-
3231
try:
3332
from mpd.twisted import MPDProtocol
3433
except ImportError:
3534

36-
class MPDProtocol:
37-
def __init__():
38-
raise "No twisted module found"
35+
class MPDProtocolDummy:
36+
def __init__(self) -> None:
37+
raise Exception("No twisted module found")
38+
39+
MPDProtocol = MPDProtocolDummy # type: ignore

0 commit comments

Comments
 (0)