From 0c2808e5765f27d82c388f885bee42b87ac1c4f8 Mon Sep 17 00:00:00 2001 From: Mirko Bonadei Date: Tue, 12 Jan 2021 14:34:25 +0100 Subject: [PATCH] Remove CheckCompile method from MetaBuildWrapper. This method is unused and it is not present in Chromium's mb.py, since part of it needs to be renamed as part of [1], this CL take the opportunity to delete it. [1] - https://webrtc-review.googlesource.com/c/src/+/201382 Bug: None Change-Id: I9b231b2dd2ffbc61084cbfbf9bd8de95407f6b5f Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/201383 Reviewed-by: Dirk Pranke Commit-Queue: Mirko Bonadei Cr-Commit-Position: refs/heads/master@{#32960} --- tools_webrtc/mb/mb.py | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/tools_webrtc/mb/mb.py b/tools_webrtc/mb/mb.py index 6287ca2366..67d25d025a 100755 --- a/tools_webrtc/mb/mb.py +++ b/tools_webrtc/mb/mb.py @@ -1069,27 +1069,6 @@ class MetaBuildWrapper(object): raise MBErr('Error %s writing to the output path "%s"' % (e, path)) - def CheckCompile(self, master, builder): - url_template = self.args.url_template + '/{builder}/builds/_all?as_text=1' - url = urllib2.quote(url_template.format(master=master, builder=builder), - safe=':/()?=') - try: - builds = json.loads(self.Fetch(url)) - except Exception as e: - return str(e) - successes = sorted( - [int(x) for x in builds.keys() if "text" in builds[x] and - cmp(builds[x]["text"][:2], ["build", "successful"]) == 0], - reverse=True) - if not successes: - return "no successful builds" - build = builds[str(successes[0])] - step_names = set([step["name"] for step in build["steps"]]) - compile_indicators = set(["compile", "compile (with patch)", "analyze"]) - if compile_indicators & step_names: - return "compiles" - return "does not compile" - def PrintCmd(self, cmd, env): if self.platform == 'win32': env_prefix = 'set '