#2175: Wrong ordering of next builds in the waterfall display?
----------------------+-----------------------
Reporter:  iustin     |      Owner:
    Type:  undecided  |     Status:  new
Priority:  trivial    |  Milestone:  undecided
 Version:  0.8.5      |   Keywords:
----------------------+-----------------------
 Hi,

 I'm not entirely sure but I think there's a cosmetic bug in the waterfall
 display. I have some periodic builders and this is how the display looks:

 {{{
 waiting
 next in ~ 18 hrs 56 mins at 08:00
 next in ~ 2 hrs 56 mins at 16:00
 next in ~ 10 hrs 56 mins at 00:00
 }}}

 For another builder, it is:

 {{{
 waiting
 next in ~ 20 hrs 56 mins at 10:00
 next in ~ 4 hrs 56 mins at 18:00
 next in ~ 12 hrs 56 mins at 02:00
 }}}

 Normally I would expect these to be sorted in terms of start time, and not
 somewhat random (I can't find the logic here).

 I think this is due to the fact that in waterfally.py, the code does:

 {{{
 for t in upcoming:
     if t is not None:
         eta = t - util.now()
         text.extend(self.formatETA("next in", eta))
 }}}

 without ordering the upcoming list beforehand. Simply changing this to:

 {{{
 for t in sorted(upcoming):
   …
 }}}

 fixes the display for me, but I don't know if the upcoming list will
 always hold just integers so that sort makes sense.

-- 
Ticket URL: <http://trac.buildbot.net/ticket/2175>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
------------------------------------------------------------------------------
RSA(R) Conference 2012
Mar 27 - Feb 2
Save $400 by Jan. 27
Register now!
http://p.sf.net/sfu/rsa-sfdev2dev2
_______________________________________________
Buildbot-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/buildbot-commits

Reply via email to