|
Lines 304-309
class PatchProcessingQueue(AbstractPatchQueue):
a/Tools/Scripts/webkitpy/tool/commands/queues.py_sec1
|
| 304 |
|
304 |
|
| 305 |
self._create_port() |
305 |
self._create_port() |
| 306 |
|
306 |
|
|
|
307 |
# FIXME: Bugzilla member functions should perform this check as they can do it as part of the same |
| 308 |
# network request. This would also avoid bugs where the access of the Bugzilla bug changes between |
| 309 |
# the time-of-check (calling this function) and time-of-use (when we ask Bugzilla to perform the |
| 310 |
# actual operation). |
| 311 |
def _can_access_bug(self, bug_id): |
| 312 |
return bool(self._tool.bugs.fetch_bug(bug_id)) |
| 313 |
|
| 307 |
def _upload_results_archive_for_patch(self, patch, results_archive_zip): |
314 |
def _upload_results_archive_for_patch(self, patch, results_archive_zip): |
| 308 |
if not self._port: |
315 |
if not self._port: |
| 309 |
self._create_port() |
316 |
self._create_port() |
|
Lines 321-327
class PatchProcessingQueue(AbstractPatchQueue):
a/Tools/Scripts/webkitpy/tool/commands/queues.py_sec2
|
| 321 |
# FIXME: We could easily list the test failures from the archive here, |
328 |
# FIXME: We could easily list the test failures from the archive here, |
| 322 |
# currently callers do that separately. |
329 |
# currently callers do that separately. |
| 323 |
comment_text += BotInfo(self._tool, self._port.name()).summary_text() |
330 |
comment_text += BotInfo(self._tool, self._port.name()).summary_text() |
| 324 |
self._tool.bugs.add_attachment_to_bug(patch.bug_id(), results_archive_file, description, filename="layout-test-results.zip", comment_text=comment_text) |
331 |
if self._can_access_bug(patch.bug_id()): |
|
|
332 |
self._tool.bugs.add_attachment_to_bug(patch.bug_id(), results_archive_file, description, filename="layout-test-results.zip", comment_text=comment_text) |
| 325 |
|
333 |
|
| 326 |
|
334 |
|
| 327 |
class CommitQueue(PatchProcessingQueue, StepSequenceErrorHandler, CommitQueueTaskDelegate): |
335 |
class CommitQueue(PatchProcessingQueue, StepSequenceErrorHandler, CommitQueueTaskDelegate): |
|
Lines 355-362
class CommitQueue(PatchProcessingQueue, StepSequenceErrorHandler, CommitQueueTas
a/Tools/Scripts/webkitpy/tool/commands/queues.py_sec3
|
| 355 |
self._did_error(patch, "%s did not process patch. Reason: %s" % (self.name, error.failure_message)) |
363 |
self._did_error(patch, "%s did not process patch. Reason: %s" % (self.name, error.failure_message)) |
| 356 |
return False |
364 |
return False |
| 357 |
except ScriptError as e: |
365 |
except ScriptError as e: |
| 358 |
validator = CommitterValidator(self._tool) |
366 |
if self._can_access_bug(patch.bug_id()): |
| 359 |
validator.reject_patch_from_commit_queue(patch.id(), self._error_message_for_bug(task, patch, e)) |
367 |
validator = CommitterValidator(self._tool) |
|
|
368 |
validator.reject_patch_from_commit_queue(patch.id(), self._error_message_for_bug(task, patch, e)) |
| 360 |
results_archive = task.results_archive_from_patch_test_run(patch) |
369 |
results_archive = task.results_archive_from_patch_test_run(patch) |
| 361 |
if results_archive: |
370 |
if results_archive: |
| 362 |
self._upload_results_archive_for_patch(patch, results_archive) |
371 |
self._upload_results_archive_for_patch(patch, results_archive) |