Skip to content

Commit 881069b

Browse files
committed
fix(addons): make error paths explicit for CodeQL
1 parent a99a04b commit 881069b

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/ha_mcp/tools/tools_addons.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -603,6 +603,7 @@ def _supervisor_result_mapping(
603603
context={"endpoint": endpoint, "method": verb},
604604
)
605605
)
606+
raise AssertionError("unreachable: raise_tool_error always raises")
606607

607608

608609
async def _supervisor_api_call(
@@ -2647,6 +2648,7 @@ def _repo_noop_or_raise(
26472648
if error_code != ErrorCode.SERVICE_CALL_FAILED.value:
26482649
raise error
26492650
self._raise_repo_action_error(key, repository, error_text)
2651+
raise AssertionError("unreachable: _raise_repo_action_error always raises")
26502652

26512653
@staticmethod
26522654
def _structured_error_code(error_text: str) -> str | None:

0 commit comments

Comments
 (0)