Skip to content

Commit

Permalink
Merge pull request #74 from tekktrik/dev/fix-pylint
Browse files Browse the repository at this point in the history
Fix pylint errors
  • Loading branch information
kattni authored Nov 8, 2022
2 parents ec21dcd + 3e1f4fb commit 9235540
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions adafruit_wiznet5k/adafruit_wiznet5k.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ class WIZNET5K: # pylint: disable=too-many-public-methods, too-many-instance-at
def __init__(
self,
spi_bus,
cs,
cs, # pylint: disable=invalid-name
reset=None,
is_dhcp=True,
mac=DEFAULT_MAC,
Expand Down Expand Up @@ -493,8 +493,8 @@ def write(self, addr, callback, data):
if hasattr(data, "from_bytes"):
bus_device.write(bytes([data])) # pylint: disable=no-member
else:
for i, _ in enumerate(data):
bus_device.write(bytes([data[i]])) # pylint: disable=no-member
for data_comp in data:
bus_device.write(bytes([data_comp])) # pylint: disable=no-member

# Socket-Register API

Expand Down
6 changes: 3 additions & 3 deletions adafruit_wiznet5k/adafruit_wiznet5k_dns.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,11 +240,11 @@ def _build_dns_question(self):
host = self._host.decode("utf-8")
host = host.split(".")
# write out each section of host
for i, _ in enumerate(host):
for data in host:
# append the sz of the section
self._pkt_buf.append(len(host[i]))
self._pkt_buf.append(len(data))
# append the section data
self._pkt_buf += bytes(host[i], "utf-8")
self._pkt_buf += bytes(data, "utf-8")
# end of the name
self._pkt_buf.append(0x00)
# Type A record
Expand Down

0 comments on commit 9235540

Please sign in to comment.