Changeset 51622 in webkit
- Timestamp:
- Dec 2, 2009 9:31:48 PM (14 years ago)
- Location:
- trunk/WebKitTools
- Files:
-
- 1 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKitTools/ChangeLog
r51619 r51622 1 2009-12-02 Eric Seidel <eric@webkit.org> 2 3 Reviewed by Adam Barth. 4 5 REGRESSION(51595): commit-queue is throwing exceptions 6 https://bugs.webkit.org/show_bug.cgi?id=32083 7 8 * Scripts/modules/commands/queues.py: 9 - Don't use default value of [] as it ends up getting shared. 10 - Make log_progress accept arrays of ints as well as strings. 11 - Return an exit code from execute() 12 * Scripts/modules/commands/queues_unittest.py: Added. 13 - Test to make sure log_progress will accept ints. 14 - Test to make sure run_bugzilla_tool will accept ints. 15 * Scripts/modules/workqueue.py: 16 - Print the stack trace on unexpected exceptions for easier debugging. 17 * Scripts/run-webkit-unittests: 18 - Add queues_unittest. 19 20 * Scripts/modules/commands/queues.py: 21 * Scripts/modules/commands/queues_unittest.py: Copied from WebKitTools/Scripts/modules/commands/commandtest.py. 22 * Scripts/modules/mock_bugzillatool.py: 23 * Scripts/modules/workqueue.py: 24 * Scripts/run-webkit-unittests: 25 1 26 2009-12-02 David Levin <levin@chromium.org> 2 27 -
trunk/WebKitTools/Scripts/modules/commands/queues.py
r51590 r51622 47 47 class AbstractQueue(Command, WorkQueueDelegate): 48 48 watchers = "webkit-bot-watchers@googlegroups.com" 49 def __init__(self, options= []):50 options +=[49 def __init__(self, options=None): # Default values should never be collections (like []) as default values are shared between invocations 50 options_list = (options or []) + [ 51 51 make_option("--no-confirm", action="store_false", dest="confirm", default=True, help="Do not ask the user for confirmation before running the queue. Dangerous!"), 52 52 make_option("--status-host", action="store", type="string", dest="status_host", default=StatusBot.default_host, help="Hostname (e.g. localhost or commit.webkit.org) where status updates should be posted."), 53 53 ] 54 Command.__init__(self, "Run the %s" % self.name, options=options )54 Command.__init__(self, "Run the %s" % self.name, options=options_list) 55 55 56 56 def _cc_watchers(self, bug_id): … … 93 93 94 94 def run_bugzilla_tool(self, args): 95 bugzilla_tool_args = [self.tool.path()] + args95 bugzilla_tool_args = [self.tool.path()] + map(str, args) 96 96 run_and_throw_if_fail(bugzilla_tool_args) 97 97 98 98 def log_progress(self, patch_ids): 99 log("%s in %s [%s]" % (pluralize("patch", len(patch_ids)), self.name, ", ".join( patch_ids)))99 log("%s in %s [%s]" % (pluralize("patch", len(patch_ids)), self.name, ", ".join(map(str, patch_ids)))) 100 100 101 101 def execute(self, options, args, tool): … … 103 103 self.tool = tool 104 104 work_queue = WorkQueue(self.name, self) 105 work_queue.run()105 return work_queue.run() 106 106 107 107 … … 147 147 148 148 class AbstractTryQueue(AbstractQueue, PersistentPatchCollectionDelegate, LandingSequenceErrorHandler): 149 def __init__(self, options= []):149 def __init__(self, options=None): 150 150 AbstractQueue.__init__(self, options) 151 151 -
trunk/WebKitTools/Scripts/modules/mock_bugzillatool.py
r51464 r51622 131 131 def scm(self): 132 132 return self._scm 133 134 def path(self): 135 return "echo" -
trunk/WebKitTools/Scripts/modules/workqueue.py
r51277 r51622 31 31 import os 32 32 import time 33 import traceback 33 34 34 35 from datetime import datetime, timedelta … … 105 106 continue 106 107 self.status_bot.update_status(self._name, waiting_message, patch) 108 except KeyboardInterrupt, e: 109 log("\nUser terminated queue.") 110 return 1 107 111 except Exception, e: 112 traceback.print_exc() 108 113 # Don't try tell the status bot, in case telling it causes an exception. 109 114 self._sleep("Exception while preparing queue: %s." % e) -
trunk/WebKitTools/Scripts/run-webkit-unittests
r51442 r51622 36 36 from modules.commands.upload_unittest import * 37 37 from modules.commands.queries_unittest import * 38 from modules.commands.queues_unittest import * 38 39 from modules.committers_unittest import * 39 40 from modules.cpp_style_unittest import *
Note: See TracChangeset
for help on using the changeset viewer.