skip jobs with no builds

This commit is contained in:
Hannes Mehnert 2023-09-18 11:37:02 +02:00 committed by Reynir Björnsson
parent 8dedc8b95b
commit 95b4856179

View file

@ -280,9 +280,12 @@ let routes ~datadir ~cachedir ~configdir =
Log.warn (fun m -> m "Job without builds: %s" job_name); Log.warn (fun m -> m "Job without builds: %s" job_name);
Lwt_result.return acc) Lwt_result.return acc)
ps (Lwt_result.return []) >>= fun platform_builds -> ps (Lwt_result.return []) >>= fun platform_builds ->
let v = (job_name, synopsis, platform_builds) in if platform_builds = [] then
let section = Option.value ~default:"Uncategorized" section in Lwt_result.return acc
Lwt_result.return (Utils.String_map.add_or_create section v acc)) else
let v = (job_name, synopsis, platform_builds) in
let section = Option.value ~default:"Uncategorized" section in
Lwt_result.return (Utils.String_map.add_or_create section v acc))
jobs jobs
(Lwt_result.return Utils.String_map.empty) (Lwt_result.return Utils.String_map.empty)
|> if_error "Error getting jobs" |> if_error "Error getting jobs"