branch: main
commit f282178d3fb459e30eb61e3c6cb913d2ccb30eb3
Author: Romain GARBAGE <romain.garb...@inria.fr>
AuthorDate: Wed May 7 11:18:27 2025 +0200

    http: Implement spec update for /admin/forgejo/event endpoint.
    
    * src/cuirass/http.scm (url-handler): Update specification when receiving a
    "synchronized" Forgejo pull request event.
    
    Signed-off-by: Ludovic Courtès <l...@gnu.org>
---
 src/cuirass/http.scm | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/cuirass/http.scm b/src/cuirass/http.scm
index 61636bd..01c93e4 100644
--- a/src/cuirass/http.scm
+++ b/src/cuirass/http.scm
@@ -833,12 +833,12 @@ return DEFAULT."
                   ;; Pull request is updated.
                   ('synchronized
                    (if (db-get-specification spec-name)
-                       (if (call-bridge `(trigger-jobset ,(specification-name 
spec))
-                                        bridge)
+                       (if (call-bridge `(update-jobset ,(specification-name 
spec))
+                                          bridge)
                            (respond-json (scm->json-string `((jobset . 
,spec-name))))
                            (begin
-                             (log-warning "evaluation hook disabled")
-                             (respond-json-with-error 400 "Evaluation hook 
disabled.")))
+                             (log-error "unable to update specification ~a" 
spec-name)
+                             (respond-json-with-error 400 "Unable to update 
specification.")))
                        (respond-json-with-error 404 "Jobset not found.")))
                   ;; Other action where nothing is done.
                   (_

Reply via email to