Skip to content
Snippets Groups Projects
Unverified Commit 54244e6e authored by Mathieu Othacehe's avatar Mathieu Othacehe
Browse files

database: Fix "db-update-build-status!".

* src/cuirass/database.scm (db-update-build-status): Only consider evaluations
that happened before the current one. This is useful when updating the build
status of old evaluations.
parent 7697735f
No related branches found
No related tags found
No related merge requests found
......@@ -797,14 +797,16 @@ log file for DRV."
UPDATE Builds SET stoptime =" now
", status =" status
", last_status =
(SELECT Builds.status FROM (SELECT job_name, specification FROM Builds
(SELECT Builds.status FROM
(SELECT evaluation, job_name, specification FROM Builds
INNER JOIN Evaluations ON Builds.evaluation = Evaluations.id WHERE
derivation = " drv ") AS cur, Builds INNER JOIN
Evaluations ON Builds.evaluation = Evaluations.id
WHERE cur.job_name = Builds.job_name AND
cur.specification = Evaluations.specification AND
Builds.evaluation < cur.evaluation AND
Builds.status >= 0
ORDER BY evaluation DESC LIMIT 1)
ORDER BY Builds.evaluation DESC LIMIT 1)
WHERE derivation =" drv
" AND status != " status ";")))
(when (positive? rows)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment