diff --git a/robot-server/robot_server/subsystems/firmware_update_manager.py b/robot-server/robot_server/subsystems/firmware_update_manager.py index 12aacc4feb47..b353a5661cb4 100644 --- a/robot-server/robot_server/subsystems/firmware_update_manager.py +++ b/robot-server/robot_server/subsystems/firmware_update_manager.py @@ -148,6 +148,8 @@ def __init__( self._status_cache_lock = Lock() self._created_at = created_at self._update_id = update_id + # mypy thinks this is assignment to a method, which it is not. that means + # it's ok to assign this and it's also okay to not take a self argument self._complete_callback = complete_callback @property @@ -204,6 +206,8 @@ async def _update_task(self) -> None: UpdateProgress(UpdateState.failed, last_progress, be) ) finally: + # mypy continues to think this is a method but it is a function stored in an + # attribute and therefore does not need a self argument await self._complete_callback() def get_handle(self) -> "UpdateProcessHandle":