Index: apimod.scm ================================================================== --- apimod.scm +++ apimod.scm @@ -259,13 +259,13 @@ ((csv->test-data) (apply db:csv->test-data dbstruct params)) ;; MISC ;; ((sync-inmem->db) (let ((run-id (car params))) ;; (db:sync-touched dbstruct run-id force-sync: #t))) - ;; ((mark-incomplete) (apply db:find-and-mark-incomplete dbstruct params)) - ;; ((create-all-triggers) (db:create-all-triggers dbstruct)) - ;; ((drop-all-triggers) (db:drop-all-triggers dbstruct)) + ((mark-incomplete) (apply db:find-and-mark-incomplete dbstruct params)) + ((create-all-triggers) (db:create-all-triggers dbstruct)) + ((drop-all-triggers) (db:drop-all-triggers dbstruct)) ;; TESTMETA ((testmeta-add-record) (apply db:testmeta-add-record dbstruct params)) ((testmeta-update-field) (apply db:testmeta-update-field dbstruct params)) ((get-tests-tags) (db:get-tests-tags dbstruct)) @@ -417,22 +417,22 @@ (define (api:process-request dbstruct indat) ;; the $ is the request vars proc (let* ((cmd-in (alist-ref 'cmd indat)) ;; ($ 'cmd)) (cmd (if (string? cmd-in)(string->symbol cmd-in) cmd-in)) (params (alist-ref 'params indat)) (key (alist-ref 'key indat)) ;; TODO - add this back - (doprint (apply common:low-noise-print 10 params)) + ;; (doprint (apply common:low-noise-print 10 params)) ) - (if doprint (debug:print 0 *default-log-port* "cmd: " cmd " with params: " params ", key: " key)) + ;; (if doprint (debug:print 0 *default-log-port* "cmd: " cmd " with params: " params ", key: " key)) (case cmd-in ((ping) #t) ;; ((quit) (exit)) (else (if (equal? key *my-signature*) ;; TODO - get real key involved (begin (set! *api-process-request-count* (+ *api-process-request-count* 1)) (let* ((res (api:execute-requests dbstruct cmd params))) - (if doprint (debug:print 0 *default-log-port* "res:" res)) + ;; (if doprint (debug:print 0 *default-log-port* "res:" res)) #;(if (not success) (debug:print 0 *default-log-port* "ERROR: success flag is #f for " cmd " with params " params)) (if (> *api-process-request-count* *max-api-process-requests*) (set! *max-api-process-requests* *api-process-request-count*)) (set! *api-process-request-count* (- *api-process-request-count* 1)) Index: dbmod.scm ================================================================== --- dbmod.scm +++ dbmod.scm @@ -1439,11 +1439,11 @@ (define (db:create-all-triggers dbstruct run-id) (db:with-db dbstruct run-id #f (lambda (db) (db:create-triggers db)))) - +; "SELECT count(id) FROM tests WHERE state in ('RUNNING','LAUNCHED','REMOTEHOSTSTART') AND run_id= (define (db:create-triggers db) (for-each (lambda (key) (sqlite3:execute db (cadr key))) db:trigger-list)) Index: megatest.scm ================================================================== --- megatest.scm +++ megatest.scm @@ -890,12 +890,12 @@ (hash-table-delete! args:arg-hash "-itempatt"))) (if (args:get-arg "-runtests") (debug:print 0 *default-log-port* "WARNING: \"-runtests\" is deprecated. Use \"-run\" with \"-testpatt\" instead")) - (debug:print 0 *default-log-port* "on-exit disabled. Please re-enable") - ;; (on-exit std-exit-procedure) + ;; (debug:print 0 *default-log-port* "on-exit disabled. Please re-enable") + (on-exit std-exit-procedure) ;;====================================================================== ;; Misc general calls ;;====================================================================== Index: runsmod.scm ================================================================== --- runsmod.scm +++ runsmod.scm @@ -648,16 +648,17 @@ (runs:find-and-mark-incomplete-and-check-end-of-run run-id #f)))) ;; ovr-deadtime))) ;; could be root of https://hsdes.intel.com/appstore/article/#/220546828/main -- Title: Megatest jobs show DEAD even though they are still running (1.64/27) run-ids))) "runs: mark-incompletes"))) ;; (thread-start! th1) (thread-start! th2) - ;; (thread-join! th1) + (thread-join! th2) ;; turn off marking incompletes in parallel. see if it is related to the db locks we are seeing. + ;; just do the main stuff in the main thread (runs:run-tests-queue run-id runname test-records keyvals flags test-patts required-tests (any->number reglen) all-tests-registry) (set! keep-going #f) - (thread-join! th2) + ;; (thread-join! th2) ;; if run-count > 0 call, set -preclean and -rerun STUCK/DEAD (if (> run-count 0) ;; handle reruns (begin (if (not (hash-table-ref/default flags "-preclean" #f)) (hash-table-set! flags "-preclean" #t))