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

Unified Diff: client/swarming.py

Issue 1939343002: swarming: change meaning of inputs_ref (Closed) Base URL: https://chromium.googlesource.com/external/github.com/luci/luci-py@master
Patch Set: fix templates Created 4 years, 7 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 | « appengine/swarming/templates/user_task.html ('k') | client/tests/swarming_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/swarming.py
diff --git a/client/swarming.py b/client/swarming.py
index 4e0cbf17fb73b5430672b89b5438c5ee1ac2e186..8d433a333343a7fed43b6518b1808c4b758c9c81 100755
--- a/client/swarming.py
+++ b/client/swarming.py
@@ -121,9 +121,9 @@ def isolated_handle_options(options, args):
options.isolated)
inputs_ref = FilesRef(
- isolated=options.isolated,
- isolatedserver=options.isolate_server,
- namespace=options.namespace)
+ isolated=options.isolated,
+ isolatedserver=options.isolate_server,
+ namespace=options.namespace)
return isolated_cmd_args, inputs_ref
@@ -930,14 +930,15 @@ def process_trigger_options(parser, options, args):
except ValueError as e:
parser.error(str(e))
- # If inputs_ref is used, command is actually extra_args. Otherwise it's an
- # actual command to run.
+ # If inputs_ref.isolated is used, command is actually extra_args.
+ # Otherwise it's an actual command to run.
+ isolated_input = inputs_ref and inputs_ref.isolated
properties = TaskProperties(
- command=None if inputs_ref else command,
+ command=None if isolated_input else command,
dimensions=options.dimensions,
env=options.env,
execution_timeout_secs=options.hard_timeout,
- extra_args=command if inputs_ref else None,
+ extra_args=command if isolated_input else None,
grace_period_secs=30,
idempotent=options.idempotent,
inputs_ref=inputs_ref,
@@ -1378,7 +1379,7 @@ def CMDreproduce(parser, args):
else:
env[key] = i['value'].encode('utf-8')
- if properties.get('inputs_ref'):
+ if (properties.get('inputs_ref') or {}).get('isolated'):
# Create the tree.
with isolateserver.get_storage(
properties['inputs_ref']['isolatedserver'],
« no previous file with comments | « appengine/swarming/templates/user_task.html ('k') | client/tests/swarming_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698