Skip to content

Commit 66b9935

Browse files
committed
Remove return statement in finally clause
1 parent 048c5b0 commit 66b9935

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

src/isar/robot/robot_service.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,8 +176,7 @@ def request_inspection_upload(task: InspectionTask) -> None:
176176
)
177177
except asyncio.CancelledError:
178178
pass
179-
finally:
180-
return mission if remaining_mission is None else remaining_mission
179+
return mission if remaining_mission is None else remaining_mission
181180

182181
def _register_status_threads(self) -> None:
183182
self.status_thread = RobotStatusThread(

tests/isar/services/robot/test_robot_service.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def test_successful_stop_with_no_remaining_tasks(
134134

135135
mocker.patch(
136136
"isar.robot.robot_service.robot_monitor_mission",
137-
return_value=(None, mission),
137+
return_value=(None, mission, True),
138138
)
139139

140140
async def test_stop_mission_handler() -> None:

0 commit comments

Comments
 (0)