Skip to content

Commit

Permalink
discover: Ignore pylint error regarding too many nested blocks
Browse files Browse the repository at this point in the history
This adds an ignore statement for the `too-many-blocks` error to the
discover function. The code seems to be fine and needs to handle all of
those exceptions in try blocks. It's still readable perfectly fine, so
let's ignore this error for now.
  • Loading branch information
kbabioch authored and Bouni committed Jan 21, 2023
1 parent 7ea0c66 commit 72f2a05
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions luxtronik/discover.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def discover() -> list[(str, int)]:

results: list[(str, int)] = []

# pylint: disable=too-many-nested-blocks
for port in LUXTRONIK_DISCOVERY_PORTS:
LOGGER.debug("Send discovery packets to port %s", port)
server = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, socket.IPPROTO_UDP)
Expand Down

0 comments on commit 72f2a05

Please sign in to comment.