Skip to content

Commit 78d1610

Browse files
committed
fix read_pulses for pylint by having one positional arg
1 parent 77b83b1 commit 78d1610

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

adafruit_irremote.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,8 +222,7 @@ def _read_pulses_non_blocking(self, input_pulses, max_pulse=10000, pulse_window=
222222
recent_count = 0
223223
time.sleep(pulse_window)
224224

225-
# pylint: disable-msg=too-many-arguments
226-
def read_pulses(self, input_pulses, max_pulse=10000, blocking=True,
225+
def read_pulses(self, input_pulses, *, max_pulse=10000, blocking=True,
227226
pulse_window=0.10, blocking_delay=0.10):
228227
"""Read out a burst of pulses until pulses stop for a specified
229228
period (pulse_window), pruning pulses after a pulse longer than ``max_pulse``.
@@ -242,7 +241,6 @@ def read_pulses(self, input_pulses, max_pulse=10000, blocking=True,
242241
time.sleep(blocking_delay)
243242
continue
244243
return pulses
245-
# pylint: enable-msg=too-many-arguments
246244

247245
class GenericTransmit:
248246
"""Generic infrared transmit class that handles encoding."""

0 commit comments

Comments
 (0)