Stricter pylint (#550)

* stricter pylint

* Add as argument
This commit is contained in:
Willem Melching
2020-06-02 16:27:07 -07:00
committed by GitHub
parent a38925a0a4
commit e0a706e4f0
24 changed files with 83 additions and 79 deletions

View File

@@ -30,10 +30,7 @@ def build_st(target, mkfile="Makefile", clean=True):
clean_cmd = "make -f %s clean" % mkfile if clean else ":"
cmd = 'cd %s && %s && make -f %s %s' % (os.path.join(BASEDIR, "board"), clean_cmd, mkfile, target)
try:
_ = subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True)
except subprocess.CalledProcessError:
raise
_ = subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True)
def parse_can_buffer(dat):
ret = []
@@ -381,7 +378,6 @@ class Panda(object):
self._handle.controlWrite(Panda.REQUEST_OUT, 0xd1, 0, 0, b'')
except Exception as e:
print(e)
pass
def get_version(self):
return self._handle.controlRead(Panda.REQUEST_IN, 0xd6, 0, 0, 0x40).decode('utf8')

View File

@@ -18,6 +18,7 @@
# this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
# Street, Fifth Floor, Boston, MA 02110-1301 USA.
# pylint: skip-file
# flake8: noqa
import argparse

View File

@@ -308,7 +308,7 @@ class CanClient():
print("CAN-RX: drain - {}".format(len(msgs)))
self.rx_buff.clear()
else:
for rx_addr, rx_ts, rx_data, rx_bus in msgs or []:
for rx_addr, _, rx_data, rx_bus in msgs or []:
if self._recv_filter(rx_bus, rx_addr) and len(rx_data) > 0:
rx_data = bytes(rx_data) # convert bytearray to bytes