Changeset 174158 in webkit


Ignore:
Timestamp:
Oct 1, 2014 10:18:10 AM (10 years ago)
Author:
ap@apple.com
Message:

EWS is too eager to say that a patch does not apply to trunk of repository
https://bugs.webkit.org/show_bug.cgi?id=137290

Reviewed by Ryosuke Niwa.

  • QueueStatusServer/app.yaml: Updated app version.
  • QueueStatusServer/handlers/statusbubble.py:

(StatusBubble._build_bubble):
(StatusBubble._build_bubbles_for_attachment):
Rewrote to make more sense.

Location:
trunk/Tools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r174136 r174158  
     12014-10-01  Alexey Proskuryakov  <ap@apple.com>
     2
     3        EWS is too eager to say that a patch does not apply to trunk of repository
     4        https://bugs.webkit.org/show_bug.cgi?id=137290
     5
     6        Reviewed by Ryosuke Niwa.
     7
     8        * QueueStatusServer/app.yaml: Updated app version.
     9
     10        * QueueStatusServer/handlers/statusbubble.py:
     11        (StatusBubble._build_bubble):
     12        (StatusBubble._build_bubbles_for_attachment):
     13        Rewrote to make more sense.
     14
    1152014-09-30  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
    216
  • trunk/Tools/QueueStatusServer/app.yaml

    r174124 r174158  
    11application: webkit-queues
    2 version: 174124 # Bugzilla bug ID of last major change
     2version: 174158 # Bugzilla bug ID of last major change
    33runtime: python
    44api_version: 1
  • trunk/Tools/QueueStatusServer/handlers/statusbubble.py

    r174118 r174158  
    116116        statuses = QueueStatus.all().filter('queue_name =', queue.name()).filter('active_patch_id =', attachment.id).order('-date').fetch(limit=10)
    117117        if not statuses:
     118            bubble["had_resultative_status_other_than_failure_to_apply"] = False
    118119            if attachment.id in queue.active_work_items().item_ids:
    119120                bubble["state"] = "started"
    120121                bubble["details_message"] = "Started processing, no output yet.\n\n" + self._iso_time(queue.active_work_items().time_for_item(attachment.id))
    121                 bubble["may_fail_to_apply"] = True
    122122            else:
    123123                real_queue_position = self._real_queue_position(queue, queue_position)
     
    125125                bubble["details_message"] = "Waiting in queue, processing has not started yet.\n\nPosition in queue: " + str(real_queue_position)
    126126                bubble["queue_position"] = real_queue_position
    127                 bubble["may_fail_to_apply"] = True
    128127        else:
    129128            latest_resultative_status = self._latest_resultative_status(statuses)
     129            bubble["had_resultative_status_other_than_failure_to_apply"] = any(map(lambda status:
     130                latest_resultative_status and latest_resultative_status.message != "Error: " + queue.name() + " unable to apply patch.",
     131                statuses))
    130132            if not latest_resultative_status:
    131133                bubble["state"] = "started"
     
    147149                        bubble["details_message"] += " Some messages were logged while the patch was still eligible:\n\n"
    148150                    bubble["details_message"] += "\n".join([status.message for status in statuses[1:]]) + "\n\n" + self._iso_time(statuses[0].date)
    149                 bubble["may_fail_to_apply"] = True
    150151            elif statuses[0].message == "Error: " + queue.name() + " unable to apply patch.":
    151152                bubble["state"] = "fail"
     
    190191
    191192        failed_to_apply = any(map(lambda bubble: "failed_to_apply" in bubble, bubbles))
    192         had_output = all(map(lambda bubble: not "may_fail_to_apply" in bubble and not "failed_to_apply" in bubble, bubbles))
    193 
    194         return (bubbles, show_submit_to_ews, failed_to_apply and (not had_output) and (not show_submit_to_ews))
     193        had_resultative_status_other_than_failure_to_apply = any(map(lambda bubble: bubble["had_resultative_status_other_than_failure_to_apply"], bubbles))
     194
     195        return (bubbles, show_submit_to_ews, failed_to_apply and not had_resultative_status_other_than_failure_to_apply)
    195196
    196197    def get(self, attachment_id_string):
Note: See TracChangeset for help on using the changeset viewer.