Move archiving back to old bots until we have a prioritized pool
Currently we have to wait for other builds
Bug: 124643718
Change-Id: Id6adc2376106893366325deb8d52c27dadb2aa47
diff --git a/tools/archive.py b/tools/archive.py
index 1ce1d43..f86530a 100755
--- a/tools/archive.py
+++ b/tools/archive.py
@@ -94,9 +94,8 @@
if not utils.is_bot() and not options.dry_run:
raise Exception('You are not a bot, don\'t archive builds')
- if utils.is_old_bot():
- print("Archiving is disabled on old bots, new bots are archiving, see " +
- "https://ci.chromium.org/p/r8")
+ if utils.is_new_bot():
+ print("Archiving is disabled on new bots.")
return
# Create maven release which uses a build that exclude dependencies.
@@ -136,7 +135,7 @@
with open(version_file,'w') as version_writer:
version_writer.write('version.sha=' + GetGitHash() + '\n')
version_writer.write(
- 'releaser=go/r8bot (' + os.environ.get('SWARMING_BOT_ID') + ')\n')
+ 'releaser=go/r8bot (' + os.environ.get('BUILDBOT_SLAVENAME') + ')\n')
version_writer.write('version-file.version.code=1\n')
for file in [
diff --git a/tools/utils.py b/tools/utils.py
index 2b0caaf..f2df0ed 100644
--- a/tools/utils.py
+++ b/tools/utils.py
@@ -481,8 +481,8 @@
android_optional_jar for android_optional_jar in android_optional_jars
if os.path.isfile(android_optional_jar)]
-def is_old_bot():
- return 'BUILDBOT_BUILDERNAME' in os.environ
+def is_new_bot():
+ return 'SWARMING_BOT_ID' in os.environ
def is_bot():
return 'USER' in os.environ and os.environ['USER'] == 'chrome-bot'