Fix zero-padding in gerrit ref
authorborenet <borenet@chromium.org>
Mon, 7 Nov 2016 17:05:16 +0000 (09:05 -0800)
committerCommit bot <commit-bot@chromium.org>
Mon, 7 Nov 2016 17:05:16 +0000 (09:05 -0800)
BUG=skia:
NOTRY=true
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2484763002

Review-Url: https://codereview.chromium.org/2484763002

infra/bots/recipe_modules/core/api.py

index c851ed4..74adf6a 100644 (file)
@@ -116,8 +116,8 @@ class SkiaApi(recipe_api.RecipeApi):
     # Hack the patch ref if necessary.
     if self.m.properties.get('patch_storage', '') == 'gerrit':
       if self.m.bot_update._issue and self.m.bot_update._patchset:
-        self.m.bot_update._gerrit_ref = 'refs/changes/%d/%d/%d' % (
-            int(str(self.m.bot_update._issue)[-2:]),
+        self.m.bot_update._gerrit_ref = 'refs/changes/%s/%d/%d' % (
+            str(self.m.bot_update._issue)[-2:],
             self.m.bot_update._issue,
             self.m.bot_update._patchset,
         )