Bug 1603523 - [tryselect] Don't save fuzzy presets without a query, r=egao
authorAndrew Halberstadt <ahalberstadt@mozilla.com>
Thu, 12 Dec 2019 22:02:25 +0000
changeset 506914 2e490fe1a73ec9bd8ce775ce092dda9ebcbf8894
parent 506913 dc97cf74084d7ae872e278535895684e94b48bf7
child 506915 ac0df4ca8d54d830630b1ea9d803da082fc97fec
push id36915
push userrgurzau@mozilla.com
push dateFri, 13 Dec 2019 21:43:22 +0000
treeherdermozilla-central@f09f24f2b545 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersegao
bugs1603523
milestone73.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1603523 - [tryselect] Don't save fuzzy presets without a query, r=egao Differential Revision: https://phabricator.services.mozilla.com/D56982
tools/tryselect/mach_commands.py
--- a/tools/tryselect/mach_commands.py
+++ b/tools/tryselect/mach_commands.py
@@ -298,16 +298,18 @@ class TrySelect(MachCommandBase):
 
         if kwargs.get('save') and not kwargs.get('query'):
             # If saving preset without -q/--query, allow user to use the
             # interface to build the query.
             kwargs_copy = kwargs.copy()
             kwargs_copy['push'] = False
             kwargs_copy['save'] = None
             kwargs['query'] = self.run(save_query=True, **kwargs_copy)
+            if not kwargs['query']:
+                return
 
         if kwargs.get('paths'):
             kwargs['test_paths'] = kwargs['paths']
 
         return self.run(**kwargs)
 
     @SubCommand('try',
                 'chooser',