Changeset 51021 in webkit
- Timestamp:
- Nov 16, 2009 2:50:50 AM (14 years ago)
- Location:
- trunk/WebKitTools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKitTools/ChangeLog
r51020 r51021 1 2009-11-16 Eric Seidel <eric@webkit.org> 2 3 Reviewed by Adam Barth. 4 5 land-patches needs to be re-factored into smaller chunks 6 https://bugs.webkit.org/show_bug.cgi?id=31532 7 8 The next patch will move these methods into WebKitLandingScripts. 9 10 * Scripts/bugzilla-tool: 11 - Split out _land_patch and _close_bug_if_no_active_patches. 12 1 13 2009-11-16 Adam Barth <abarth@webkit.org> 2 14 -
trunk/WebKitTools/Scripts/bugzilla-tool
r51019 r51021 383 383 384 384 @classmethod 385 def land_patches(cls, bug_id, patches, options, tool): 385 def _close_bug_if_no_active_patches(cls, patch, option, tool): 386 # This should check to make sure there are no r? or r+ patches on the bug before closing. 387 # https://bugs.webkit.org/show_bug.cgi?id=28230 388 tool.bugs.close_bug_as_fixed(bug_id, "All reviewed patches have been landed. Closing bug.") 389 390 @classmethod 391 def _land_patch(cls, patch, options, tool): 392 tool.scm().update_webkit() # Update before every patch in case the tree has changed 393 log("Applying %s from bug %s." % (patch['id'], patch['bug_id'])) 394 tool.scm().apply_patch(patch, force=options.commit_queue) 395 396 # Make sure the tree is still green after updating, before building this patch. 397 # The first patch ends up checking tree status twice, but that's OK. 398 WebKitLandingScripts.ensure_builders_are_green(tool.buildbot, options) 399 comment_text = WebKitLandingScripts.build_and_commit(tool.scm(), options) 400 tool.bugs.clear_attachment_flags(patch['id'], comment_text) 401 402 @classmethod 403 def land_patches(cls, patches, options, tool): 386 404 try: 387 comment_text = ""388 405 for patch in patches: 389 tool.scm().update_webkit() # Update before every patch in case the tree has changed 390 log("Applying %s from bug %s." % (patch['id'], bug_id)) 391 tool.scm().apply_patch(patch, force=options.commit_queue) 392 # Make sure the tree is still green after updating, before building this patch. 393 # The first patch ends up checking tree status twice, but that's OK. 394 WebKitLandingScripts.ensure_builders_are_green(tool.buildbot, options) 395 comment_text = WebKitLandingScripts.build_and_commit(tool.scm(), options) 396 tool.bugs.clear_attachment_flags(patch['id'], comment_text) 397 398 if options.close_bug: 399 tool.bugs.close_bug_as_fixed(bug_id, "All reviewed patches have been landed. Closing bug.") 406 cls._land_patch(patch, options, tool) 407 if options.close_bug and patches: 408 cls._close_bug_if_no_active_patches(patches[0]['bug_id']) 400 409 except CheckoutNeedsUpdate, e: 401 410 log("Commit failed because the checkout is out of date. Please update and try again.") … … 432 441 error("bug-id(s) required") 433 442 434 # Check the tree status here so we can fail early443 # Check the tree status first so we can fail early. 435 444 WebKitLandingScripts.ensure_builders_are_green(tool.buildbot, options) 436 437 445 bugs_to_patches = self._fetch_list_of_patches_to_land(options, args, tool) 438 446 439 447 WebKitLandingScripts.prepare_clean_working_directory(tool.scm(), options) 440 441 448 for bug_id in bugs_to_patches.keys(): 442 self.land_patches(bug _id, bugs_to_patches[bug_id], options, tool)449 self.land_patches(bugs_to_patches[bug_id], options, tool) 443 450 444 451
Note: See TracChangeset
for help on using the changeset viewer.