security: fix all bandit issues
This commit is contained in:
parent
c25367d95c
commit
014596d271
5 changed files with 31 additions and 13 deletions
|
@ -42,5 +42,7 @@ def _get_alarm(target: str,
|
|||
|
||||
def get_proxy_alarm(proxy_id: int, alarm_type: str) -> Alarm:
|
||||
alarm = _get_alarm("proxy", alarm_type, proxy_id=proxy_id)
|
||||
assert(alarm is not None)
|
||||
if alarm is None:
|
||||
# mypy can't tell that this will never be reached
|
||||
raise RuntimeError("Creating an alarm must have failed.")
|
||||
return alarm
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue