separate region exceptions

This commit is contained in:
Devaev Maxim
2019-09-12 02:13:52 +03:00
parent 8214a20d4a
commit 6ce9f4c7a9
5 changed files with 15 additions and 18 deletions

View File

@@ -24,8 +24,6 @@ from typing import Dict
from typing import AsyncGenerator
from typing import Type
from ... import aioregion
from .. import BasePlugin
from .. import get_plugin_class
@@ -39,8 +37,9 @@ class AtxOperationError(AtxError):
pass
class AtxIsBusyError(AtxOperationError, aioregion.RegionIsBusyError):
pass
class AtxIsBusyError(AtxOperationError):
def __init__(self) -> None:
super().__init__("Performing another ATX operation, please try again later")
# =====

View File

@@ -26,8 +26,6 @@ from typing import Dict
from typing import Type
from typing import AsyncGenerator
from ... import aioregion
from .. import BasePlugin
from .. import get_plugin_class
@@ -61,8 +59,9 @@ class MsdNotOnKvmError(MsdOperationError):
super().__init__("MSD is not connected to KVM")
class MsdIsBusyError(MsdOperationError, aioregion.RegionIsBusyError):
pass
class MsdIsBusyError(MsdOperationError):
def __init__(self) -> None:
super().__init__("Performing another MSD operation, please try again later")
# =====