diff --git a/src/isar/state_machine/states/initiate_task.py b/src/isar/state_machine/states/initiate_task.py index 75b118cd..1b317e21 100644 --- a/src/isar/state_machine/states/initiate_task.py +++ b/src/isar/state_machine/states/initiate_task.py @@ -10,7 +10,10 @@ ThreadedRequestNotFinishedError, ) from isar.state_machine.states_enum import States -from robot_interface.models.exceptions import RobotException, RobotInvalidTaskExpection +from robot_interface.models.exceptions import ( + RobotException, + RobotInfeasibleTaskException, +) from robot_interface.models.mission.status import TaskStatus if TYPE_CHECKING: @@ -92,7 +95,7 @@ def _run(self): time.sleep(self.state_machine.sleep_time) continue - except RobotInvalidTaskExpection: + except RobotInfeasibleTaskException: self.state_machine.current_task.status = TaskStatus.Failed self.logger.warning( f"Failed to initiate {type(self.state_machine.current_task).__name__}" diff --git a/src/robot_interface/models/exceptions/__init__.py b/src/robot_interface/models/exceptions/__init__.py index 725d84f6..318eb5af 100644 --- a/src/robot_interface/models/exceptions/__init__.py +++ b/src/robot_interface/models/exceptions/__init__.py @@ -1,6 +1,6 @@ from .robot_exceptions import ( RobotCommunicationException, RobotException, + RobotInfeasibleTaskException, RobotInvalidResponseException, - RobotInvalidTaskExpection, ) diff --git a/src/robot_interface/models/exceptions/robot_exceptions.py b/src/robot_interface/models/exceptions/robot_exceptions.py index 9ee84476..bb4c2a84 100644 --- a/src/robot_interface/models/exceptions/robot_exceptions.py +++ b/src/robot_interface/models/exceptions/robot_exceptions.py @@ -2,11 +2,11 @@ class RobotException(Exception): pass -class RobotInvalidTaskExpection(RobotException): +class RobotCommunicationException(RobotException): pass -class RobotCommunicationException(RobotException): +class RobotInfeasibleTaskException(RobotException): pass