2481a12529
Empty sequences in Python are falsy, so if len(config_file) != 0: can be simplified to if config_file: pylint warning: C1801: Do not use `len(SEQUENCE)` to determine if a sequence is empty (len-as-condition) Simplify the code a bit with os.path.join(), which indirectly gets rid of the warning. os.path.join('', 'foo') returns 'foo', so things work out when os.path.basename() returns '' (no directory) as well. I'm getting rid of pylint warnings for a CI check. Also replace a '== None' with 'is None', which is more common. Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no> |
||
---|---|---|
.. | ||
96b_argonkey | ||
altera_max10 | ||
arc_secure_services | ||
bbc_microbit | ||
intel_s1000_crb | ||
nrf52 | ||
olimex_stm32_e407 | ||
reel_board/mesh_badge | ||
up_squared/gpio_counter | ||
boards.rst |