Skip to content

Commit

Permalink
Rename to RobotInfeasibleTaskException
Browse files Browse the repository at this point in the history
  • Loading branch information
tsundvoll committed Apr 20, 2022
1 parent e06378e commit abde3dc
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
7 changes: 5 additions & 2 deletions src/isar/state_machine/states/initiate_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down Expand Up @@ -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__}"
Expand Down
2 changes: 1 addition & 1 deletion src/robot_interface/models/exceptions/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from .robot_exceptions import (
RobotCommunicationException,
RobotException,
RobotInfeasibleTaskException,
RobotInvalidResponseException,
RobotInvalidTaskExpection,
)
4 changes: 2 additions & 2 deletions src/robot_interface/models/exceptions/robot_exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ class RobotException(Exception):
pass


class RobotInvalidTaskExpection(RobotException):
class RobotCommunicationException(RobotException):
pass


class RobotCommunicationException(RobotException):
class RobotInfeasibleTaskException(RobotException):
pass


Expand Down

0 comments on commit abde3dc

Please sign in to comment.