Overview
Comment: | Added summary tab, functional but not polished |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | dev |
Files: | files | file ages | folders |
SHA1: |
285cbc7663ee361ddcbc6deb363201ac |
User & Date: | mrwellan on 2013-07-02 00:31:48 |
Other Links: | branch diff | manifest | tags |
Context
2013-07-02
| ||
00:35 | Oops, dropped new file check-in: 79e9017edb user: mrwellan tags: dev | |
00:31 | Added summary tab, functional but not polished check-in: 285cbc7663 user: mrwellan tags: dev | |
2013-07-01
| ||
17:17 | Refactored dashboard interface to add a general info view check-in: 488a7a26c7 user: mrwellan tags: dev | |
Changes
Modified common.scm from [77700bbba2] to [616e7b9c94].
︙ | ︙ | |||
168 169 170 171 172 173 174 | (if (null? tala) ;; we are done talb (loop (car tala) (cdr tala) (car talb) (cdr talb))) #f))))) | | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | (if (null? tala) ;; we are done talb (loop (car tala) (cdr tala) (car talb) (cdr talb))) #f))))) ;;====================================================================== ;; Munge data into nice forms ;;====================================================================== ;; Generate an index for a sparse list of key values ;; ( (rowname1 colname1 val1)(rowname2 colname2 val2) ) ;; ;; => ;; ;; ( (rowname1 0)(rowname2 1)) ;; rownames -> num ;; (colname1 0)(colname2 1)) ) ;; colnames -> num ;; ;; optional apply proc to rownum colnum value (define (common:sparse-list-generate-index data #!key (proc #f)) (if (null? data) (list '() '()) (let loop ((hed (car data)) (tal (cdr data)) (rownames '()) (colnames '()) (rownum 0) (colnum 0)) (let* ((rowkey (car hed)) (colkey (cadr hed)) (value (caddr hed)) (existing-rowdat (assoc rowkey rownames)) (existing-coldat (assoc colkey colnames)) (curr-rownum (if existing-rowdat rownum (+ rownum 1))) (curr-colnum (if existing-coldat colnum (+ colnum 1))) (new-rownames (if existing-rowdat rownames (cons (list rowkey curr-rownum) rownames))) (new-colnames (if existing-coldat colnames (cons (list colkey curr-colnum) colnames)))) (debug:print-info 0 "Processing record: " hed ) (if proc (proc curr-rownum curr-colnum rowkey colkey value)) (if (null? tal) (list new-rownames new-colnames) (loop (car tal) (cdr tal) new-rownames new-colnames (if (> curr-rownum rownum) curr-rownum rownum) (if (> curr-colnum colnum) curr-colnum colnum) )))))) ;;====================================================================== ;; System stuff ;;====================================================================== ;; return a nice clean pathname made absolute (define (nice-path dir) |
︙ | ︙ |
Modified dashboard.scm from [d0fc2d7ae1] to [565f2bd4aa].
︙ | ︙ | |||
646 647 648 649 650 651 652 | ;; General info about the run(s) and megatest area (define (dashboard:summary) (let ((rawconfig (read-config (conc *toppath* "/megatest.config") #f 'return-string))) (iup:vbox (iup:hbox (dcommon:general-info) (dcommon:keys-matrix rawconfig)) | | > | 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 | ;; General info about the run(s) and megatest area (define (dashboard:summary) (let ((rawconfig (read-config (conc *toppath* "/megatest.config") #f 'return-string))) (iup:vbox (iup:hbox (dcommon:general-info) (dcommon:keys-matrix rawconfig)) (dcommon:section-matrix rawconfig "setup" "Varname" "Value") (dcommon:run-stats)))) ;;====================================================================== ;; R U N S ;;====================================================================== (define (make-dashboard-buttons nruns ntests keynames) (let* ((nkeys (length keynames)) |
︙ | ︙ |
Modified db.scm from [f833ae5945] to [15ecc35fb6].
︙ | ︙ | |||
674 675 676 677 678 679 680 681 682 683 684 685 686 687 | (sqlite3:for-each-row (lambda (count) (set! numruns count)) db "SELECT COUNT(id) FROM runs WHERE runname LIKE ? AND state != 'deleted';" runpatt) (debug:print-info 11 "db:get-num-runs END " runpatt) numruns)) ;; db:get-runs-by-patt ;; get runs by list of criteria ;; register a test run with the db ;; ;; Use: (db-get-value-by-header (db:get-header runinfo)(db:get-row runinfo)) ;; to extract info from the structure returned | > > > > > > > > > > > > > | 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 | (sqlite3:for-each-row (lambda (count) (set! numruns count)) db "SELECT COUNT(id) FROM runs WHERE runname LIKE ? AND state != 'deleted';" runpatt) (debug:print-info 11 "db:get-num-runs END " runpatt) numruns)) ;; get some basic run stats ;; ;; ( (runname (( state count ) ... )) ;; ( ... (define (db:get-run-stats db) (let ((res '())) (sqlite3:for-each-row (lambda (runname state count) (set! res (cons (list runname state count) res))) db "SELECT runname,t.state,count(t.id) FROM runs AS r INNER JOIN tests AS t ON r.id=t.run_id GROUP BY t.state,runname;" ) res)) ;; db:get-runs-by-patt ;; get runs by list of criteria ;; register a test run with the db ;; ;; Use: (db-get-value-by-header (db:get-header runinfo)(db:get-row runinfo)) ;; to extract info from the structure returned |
︙ | ︙ |
Modified mt.scm from [ae25aea357] to [8e49dc32c7].
︙ | ︙ | |||
61 62 63 64 65 66 67 | full-list new-offset limit)) full-list)))) (define (mt:get-prereqs-not-met run-id waitons ref-item-path #!key (mode 'normal)) (db:get-prereqs-not-met run-id waitons ref-item-path mode: mode)) | > > > | 61 62 63 64 65 66 67 68 69 70 | full-list new-offset limit)) full-list)))) (define (mt:get-prereqs-not-met run-id waitons ref-item-path #!key (mode 'normal)) (db:get-prereqs-not-met run-id waitons ref-item-path mode: mode)) (define (mt:get-run-stats) (cdb:remote-run db:get-run-stats #f)) |
Modified newdashboard.scm from [175248ebb1] to [bc0ac75959].
︙ | ︙ | |||
144 145 146 147 148 149 150 | (define (mkstr . x) (string-intersperse (map conc x) ",")) (define (update-search x val) (hash-table-set! *searchpatts* x val)) | < < < < < < < < < < < < < < < < < < < | 144 145 146 147 148 149 150 151 152 153 154 155 156 157 | (define (mkstr . x) (string-intersperse (map conc x) ",")) (define (update-search x val) (hash-table-set! *searchpatts* x val)) ;; mtest is actually the megatest.config file ;; (define (mtest window-id) (let* ((curr-row-num 0) (rawconfig (read-config (conc *toppath* "/megatest.config") #f 'return-string)) (keys-matrix (dcommon:keys-matrix rawconfig)) (setup-matrix (dcommon:section-matrix rawconfig "setup" "Varname" "Value")) |
︙ | ︙ | |||
850 851 852 853 854 855 856 | ;; D A S H B O A R D ;;====================================================================== ;; Main Panel (define (main-panel window-id) (iup:dialog #:title "Megatest Control Panel" | | | 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 | ;; D A S H B O A R D ;;====================================================================== ;; Main Panel (define (main-panel window-id) (iup:dialog #:title "Megatest Control Panel" #:menu (dcommon:main-menu) (let ((tabtop (iup:tabs (runs window-id) (tests window-id) (runcontrol window-id) (mtest window-id) (rconfig window-id) ))) |
︙ | ︙ |