Title: [97523] trunk/Tools
Revision
97523
Author
[email protected]
Date
2011-10-14 15:42:17 -0700 (Fri, 14 Oct 2011)

Log Message

Hide status bubbles from queues which are very far behind
https://bugs.webkit.org/show_bug.cgi?id=70133

Reviewed by Eric Seidel.

The mac-ews is so far behind that we shouldn't show its status bubble.
The status bubble just makes contributors sad.

* QueueStatusServer/handlers/statusbubble.py:

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (97522 => 97523)


--- trunk/Tools/ChangeLog	2011-10-14 22:40:22 UTC (rev 97522)
+++ trunk/Tools/ChangeLog	2011-10-14 22:42:17 UTC (rev 97523)
@@ -1,3 +1,15 @@
+2011-10-14  Adam Barth  <[email protected]>
+
+        Hide status bubbles from queues which are very far behind
+        https://bugs.webkit.org/show_bug.cgi?id=70133
+
+        Reviewed by Eric Seidel.
+
+        The mac-ews is so far behind that we shouldn't show its status bubble.
+        The status bubble just makes contributors sad.
+
+        * QueueStatusServer/handlers/statusbubble.py:
+
 2011-10-14  Dimitri Glazkov  <[email protected]>
 
         Write unit test to ensure style-checker-filter option is passed properly in webkit-patch

Modified: trunk/Tools/QueueStatusServer/handlers/statusbubble.py (97522 => 97523)


--- trunk/Tools/QueueStatusServer/handlers/statusbubble.py	2011-10-14 22:40:22 UTC (rev 97522)
+++ trunk/Tools/QueueStatusServer/handlers/statusbubble.py	2011-10-14 22:42:17 UTC (rev 97523)
@@ -37,12 +37,12 @@
 
 
 class StatusBubble(webapp.RequestHandler):
-    def _build_bubble(self, queue, attachment):
+    def _build_bubble(self, queue, attachment, queue_position):
         queue_status = attachment.status_for_queue(queue)
         bubble = {
             "name": queue.short_name().lower(),
             "attachment_id": attachment.id,
-            "queue_position": attachment.position_in_queue(queue),
+            "queue_position": queue_position,
             "state": attachment.state_from_queue_status(queue_status) if queue_status else "none",
             "status": queue_status,
         }
@@ -61,7 +61,11 @@
         for queue in Queue.all():
             if not self._have_status_for(attachment, queue):
                 continue
-            bubbles.append(self._build_bubble(queue, attachment))
+            queue_position = attachment.position_in_queue(queue)
+            if queue_position and queue_position >= 100:
+                # This queue is so far behind it's not even worth showing.
+                continue
+            bubbles.append(self._build_bubble(queue, attachment, queue_position))
             # If even one ews has status, we don't show the submit-to-ews button.
             if queue.is_ews():
                 show_submit_to_ews = False
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to