From 79d34b3b6491d6ab15eac5fb4cbfeaf632dcefa5 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Thu, 1 Apr 2021 10:53:02 +1100 Subject: [PATCH] Tools: make and declare build_binaries.py flake8-compliant --- Tools/scripts/build_binaries.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Tools/scripts/build_binaries.py b/Tools/scripts/build_binaries.py index 50ef4fdc04..092c1063d5 100755 --- a/Tools/scripts/build_binaries.py +++ b/Tools/scripts/build_binaries.py @@ -4,6 +4,8 @@ script to build the latest binaries for each vehicle type, ready to upload Peter Barker, August 2017 based on build_binaries.sh by Andrew Tridgell, March 2013 + +AP_FLAKE8_CLEAN """ from __future__ import print_function @@ -20,7 +22,8 @@ import sys import gzip # local imports -import generate_manifest, gen_stable +import generate_manifest +import gen_stable import build_binaries_history if sys.version_info[0] < 3: @@ -274,9 +277,9 @@ is bob we will attempt to checkout bob-AVR''' if not os.path.exists(versionfile): self.progress("%s does not exist" % (versionfile,)) return - ss = ".*define +FIRMWARE_VERSION[ ]+(?P\d+)[ ]*,[ ]*" \ - "(?P\d+)[ ]*,[ ]*(?P\d+)[ ]*,[ ]*" \ - "(?P[A-Z_]+)[ ]*" + ss = r".*define +FIRMWARE_VERSION[ ]+(?P\d+)[ ]*,[ ]*" \ + r"(?P\d+)[ ]*,[ ]*(?P\d+)[ ]*,[ ]*" \ + r"(?P[A-Z_]+)[ ]*" content = self.read_string_from_filepath(versionfile) match = re.search(ss, content) if match is None: @@ -721,7 +724,6 @@ is bob we will attempt to checkout bob-AVR''' "AP_Periph", "AP_Periph") - def generate_manifest(self): '''generate manigest files for GCS to download''' self.progress("Generating manifest") @@ -749,7 +751,6 @@ is bob we will attempt to checkout bob-AVR''' gen_stable.make_all_stable(self.binaries) self.progress("Generate stable releases done") - def validate(self): '''run pre-run validation checks''' if "dirty" in self.tags: