[tor-bugs] #6612 [Compass]: sort according to table header in Compass

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Nov 13 16:02:45 UTC 2012


#6612: sort according to table header in Compass
-------------------------+--------------------------------------------------
 Reporter:  gsathya      |          Owner:  gsathya
     Type:  enhancement  |         Status:  new    
 Priority:  normal       |      Milestone:         
Component:  Compass      |        Version:         
 Keywords:               |         Parent:         
   Points:               |   Actualpoints:         
-------------------------+--------------------------------------------------

Comment(by gsathya):

 {{{
 Compass sorts according to consensus_weights and then displays
 the top results. So the tablesorter sorts on top of the already sorted
 data which isn't what we want. You might want to look at:
 https://github.com/gsathya/compass/blob/master/compass.py#L303

 One approach would be to send all the data unsorted and make the
 javascript do all the sorting and display only the top results as
 specified. This means that if someone wants to see only the top 10
 results, they'd have to download all the data which is not a good
 idea.

 The other approach would be to modify compass.py to do the various
 sorting stuff. This means we'd have to refresh the page every time the
 user selects a different header to sort by. The advantage of this
 approach would be that the command line part of Compass would get all
 these benefits as well. IMHO, this approach sounds better.
 }}}

 Copy pasting conversation between cwacek and me, in case it's useful to
 someone else.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/6612#comment:5>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list