Skip to content

Commit

Permalink
Remove unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
tsundvoll committed Dec 16, 2024
1 parent 9420ebd commit a57557f
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 29 deletions.
4 changes: 1 addition & 3 deletions src/isar/apis/robot_control/robot_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@

from injector import inject

from isar.apis.models.models import (
RobotInfoResponse,
)
from isar.apis.models.models import RobotInfoResponse
from isar.config.settings import robot_settings, settings
from isar.services.utilities.robot_utilities import RobotUtilities

Expand Down
6 changes: 1 addition & 5 deletions src/isar/apis/schedule/scheduling_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,7 @@
from injector import inject

from isar.apis.models import InputPose, StartMissionResponse
from isar.apis.models.models import (
ControlMissionResponse,
RobotInfoResponse,
TaskResponse,
)
from isar.apis.models.models import ControlMissionResponse, TaskResponse
from isar.apis.models.start_mission_definition import (
StartMissionDefinition,
to_isar_mission,
Expand Down
2 changes: 1 addition & 1 deletion src/isar/mission_planner/sequential_task_selector.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
TaskSelectorInterface,
TaskSelectorStop,
)
from robot_interface.models.mission.task import TASKS, Task
from robot_interface.models.mission.task import TASKS


class SequentialTaskSelector(TaskSelectorInterface):
Expand Down
2 changes: 1 addition & 1 deletion src/isar/mission_planner/task_selector_interface.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from abc import ABCMeta, abstractmethod
from typing import List

from robot_interface.models.mission.task import TASKS, Task
from robot_interface.models.mission.task import TASKS


class TaskSelectorInterface(metaclass=ABCMeta):
Expand Down
3 changes: 2 additions & 1 deletion src/isar/state_machine/states/monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ def _run(self) -> None:

if not isinstance(status, TaskStatus):
self.logger.error(
f"Received an invalid status update when monitoring mission. Only TaskStatus is expected."
f"Received an invalid status update {status} when monitoring mission. "
"Only TaskStatus is expected."
)
break

Expand Down
13 changes: 0 additions & 13 deletions src/robot_interface/models/inspection/__init__.py
Original file line number Diff line number Diff line change
@@ -1,13 +0,0 @@
from .inspection import (
Audio,
Image,
ImageMetadata,
Inspection,
InspectionMetadata,
ThermalImage,
ThermalImageMetadata,
ThermalVideo,
ThermalVideoMetadata,
Video,
VideoMetadata,
)
2 changes: 1 addition & 1 deletion src/robot_interface/models/mission/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from pydantic import BaseModel, Field

from robot_interface.models.exceptions.robot_exceptions import ErrorMessage
from robot_interface.models.inspection import (
from robot_interface.models.inspection.inspection import (
Audio,
Image,
Inspection,
Expand Down
4 changes: 0 additions & 4 deletions tests/isar/state_machine/test_state_machine.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import time
from collections import deque
from pathlib import Path
from threading import Thread
from typing import List

import pytest
from injector import Injector
from pytest_mock import MockerFixture

from isar.config.settings import settings
from isar.mission_planner.local_planner import LocalPlanner
from isar.models.communication.queues.queues import Queues
from isar.services.utilities.scheduling_utilities import SchedulingUtilities
from isar.state_machine.state_machine import StateMachine, main
Expand All @@ -32,7 +29,6 @@

class StateMachineThread(object):
def __init__(self, injector) -> None:
# settings.UPLOAD_INSPECTIONS_ASYNC = False
self.injector: Injector = injector
self.state_machine: StateMachine = injector.get(StateMachine)
self._thread: Thread = Thread(target=main, args=[self.state_machine])
Expand Down

0 comments on commit a57557f

Please sign in to comment.