Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2112)

Unified Diff: scripts/slave/recipe_modules/skia/api.py

Issue 1829423002: Skia: Run recipes as swarming tasks (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@swarm_fix
Patch Set: Fix presubmit Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/skia_swarming/api.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/slave/recipe_modules/skia/api.py
diff --git a/scripts/slave/recipe_modules/skia/api.py b/scripts/slave/recipe_modules/skia/api.py
index bff4f38c9fdecd4733e5cfbd760e061bdbe740fb..2093c41d1711a7b15fedf42297ef30fb2611fc96 100644
--- a/scripts/slave/recipe_modules/skia/api.py
+++ b/scripts/slave/recipe_modules/skia/api.py
@@ -339,8 +339,7 @@ for pattern in build_products_whitelist:
"""Wrapper around api.file.rmtree with environment fix."""
env = {}
if self.running_in_swarming:
- env['PYTHONPATH'] = str(self.skia_dir.join('infra', 'bots', 'build',
- 'scripts'))
+ env['PYTHONPATH'] = str(self.m.path.join('build', 'scripts'))
self.m.file.rmtree(self.m.path.basename(path),
path,
env=env,
@@ -374,17 +373,15 @@ for pattern in build_products_whitelist:
def _download_and_copy_dir(self, version_file, gs_path_tmpl, host_path,
device_path, test_expected_version,
test_actual_version):
+ actual_version_file = self.m.path.join(self.tmp_dir, version_file)
# If we're running as a Swarming task, we should've received the test inputs
# via the isolate server. Only download if we're not running in Swarming.
- if self.running_in_swarming:
- actual_version_file = self.m.path.join(host_path, version_file)
- else:
+ if not self.running_in_swarming:
# Ensure that the tmp_dir exists.
self._run_once(self.m.file.makedirs,
'tmp_dir',
self.tmp_dir,
infra_step=True)
- actual_version_file = self.m.path.join(self.tmp_dir, version_file)
# Find the actually-downloaded version.
try:
@@ -423,12 +420,8 @@ for pattern in build_products_whitelist:
actual_version = expected_version
# Copy to device.
- if self.running_in_swarming:
- device_version_file = self.flavor.device_path_join(
- device_path, version_file)
- else:
- device_version_file = self.flavor.device_path_join(
- self.device_dirs.tmp_dir, version_file)
+ device_version_file = self.flavor.device_path_join(
+ self.device_dirs.tmp_dir, version_file)
if str(actual_version_file) != str(device_version_file):
try:
device_version = self.flavor.read_file_on_device(device_version_file)
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/skia_swarming/api.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698