mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2025-12-12 01:00:29 +08:00
using assert_never()
This commit is contained in:
parent
47614a5724
commit
193eaa48c8
@ -24,6 +24,7 @@ import asyncio
|
|||||||
import contextlib
|
import contextlib
|
||||||
import struct
|
import struct
|
||||||
|
|
||||||
|
import typing
|
||||||
from typing import Callable
|
from typing import Callable
|
||||||
from typing import AsyncGenerator
|
from typing import AsyncGenerator
|
||||||
|
|
||||||
@ -71,7 +72,7 @@ class _AuthApiPart(_BaseApiPart):
|
|||||||
if ex.status in [400, 401, 403]:
|
if ex.status in [400, 401, 403]:
|
||||||
return False
|
return False
|
||||||
raise
|
raise
|
||||||
raise RuntimeError("We should't be here")
|
typing.assert_never("We should't be here")
|
||||||
|
|
||||||
|
|
||||||
class _StreamerApiPart(_BaseApiPart):
|
class _StreamerApiPart(_BaseApiPart):
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user