protocol.py: Make mypy happy

This adds an assert that mypy will understand, and a type ignore because
it seems to ignore those asserts in imports
This commit is contained in:
A_D committed 2022-12-23 18:25:14 +02:00
1 parent f94072a99e
commit a930f5b902
1 file changed
+5 -1
+5 -1
View File
@@ -121,9 +121,13 @@ elif (config.auth_force_edmc_protocol
and not is_wine
and not config.auth_force_localserver
)):
# This could be false if you use auth_force_edmc_protocol, but then you get to keep the pieces
assert sys.platform == 'win32'
# spell-checker: words HBRUSH HICON WPARAM wstring WNDCLASS HMENU HGLOBAL
from ctypes import windll # type: ignore
from ctypes import POINTER, WINFUNCTYPE, Structure, byref, c_long, c_void_p, create_unicode_buffer, wstring_at
from ctypes import ( # type: ignore
POINTER, WINFUNCTYPE, Structure, byref, c_long, c_void_p, create_unicode_buffer, wstring_at
)
from ctypes.wintypes import (
ATOM, BOOL, DWORD, HBRUSH, HGLOBAL, HICON, HINSTANCE, HMENU, HWND, INT, LPARAM, LPCWSTR, LPVOID, LPWSTR, MSG,
UINT, WPARAM