diff options
author | Yunlian Jiang <yunlian@google.com> | 2017-11-22 14:06:45 -0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-11-22 21:43:10 -0800 |
commit | 2e0ad05834bfc3ce47e97af06f36d0e6a1fb7957 (patch) | |
tree | bc37189ab72fde416fb5560589445e738c14a62c /buildbot_test_toolchains.py | |
parent | 73580dd787829a4baf7039e5cf2c8d47439843a9 (diff) | |
download | toolchain-utils-2e0ad05834bfc3ce47e97af06f36d0e6a1fb7957.tar.gz |
filter out -tryjob when finding vanilla image.
We cannot find vanilla image because the build name of trybot
image was falco-release-tryjob, it then tries to find vanilla
image of falco-release-tryjob, but it could not find it.
BUG=none.
TEST=vanilla image was found.
Change-Id: I9024ea27f480db70ae296012a5958d8e243f3c38
Reviewed-on: https://chromium-review.googlesource.com/786315
Commit-Ready: Yunlian Jiang <yunlian@chromium.org>
Tested-by: Yunlian Jiang <yunlian@chromium.org>
Reviewed-by: Yunlian Jiang <yunlian@chromium.org>
Diffstat (limited to 'buildbot_test_toolchains.py')
-rwxr-xr-x | buildbot_test_toolchains.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/buildbot_test_toolchains.py b/buildbot_test_toolchains.py index a274cc5c..d8f93091 100755 --- a/buildbot_test_toolchains.py +++ b/buildbot_test_toolchains.py @@ -97,7 +97,9 @@ class ToolchainComparator(object): Returns: Latest official image name, e.g. 'daisy-release/R57-9089.0.0'. """ - mo = re.search(TRYBOT_IMAGE_RE, trybot_image) + # We need to filter out -tryjob in the trybot_image. + trybot = re.sub('-tryjob', '', trybot_image) + mo = re.search(TRYBOT_IMAGE_RE, trybot) assert mo dirname = IMAGE_DIR.replace('\\', '').format(**mo.groupdict()) return buildbot_utils.GetLatestImage(self._chromeos_root, dirname) @@ -121,7 +123,8 @@ class ToolchainComparator(object): Corresponding chrome PFQ image name, e.g. 'daisy-chrome-pfq/R40-6393.0.0-rc1'. """ - mo = re.search(TRYBOT_IMAGE_RE, trybot_image) + trybot = re.sub('-tryjob', '', trybot_image) + mo = re.search(TRYBOT_IMAGE_RE, trybot) assert mo image_dict = mo.groupdict() image_dict['image_type'] = 'chrome-pfq' |