From 0be38475b799792d5812cde52746837f8ce02d24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reynir=20Bj=C3=B6rnsson?= Date: Wed, 22 Jun 2022 08:20:29 +0000 Subject: [PATCH] builder-web: Inform expected version on wrong ver. (#121) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reviewed-on: https://git.robur.io/robur/builder-web/pulls/121 Co-authored-by: Reynir Björnsson Co-committed-by: Reynir Björnsson --- lib/builder_web.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/builder_web.ml b/lib/builder_web.ml index e4d9487..1d0ccc8 100644 --- a/lib/builder_web.ml +++ b/lib/builder_web.ml @@ -9,8 +9,8 @@ let pp_error ppf = function | #Model.error as e -> Model.pp_error ppf e | `Wrong_version (application_id, version) -> if application_id = Builder_db.application_id - then Format.fprintf ppf "Wrong database version: %Ld" version - else Format.fprintf ppf "Wrong database application id: %ld" application_id + then Format.fprintf ppf "Wrong database version: %Ld, expected %Ld" version Builder_db.current_version + else Format.fprintf ppf "Wrong database application id: %ld, expected %ld" application_id Builder_db.application_id let init_datadir datadir = let ( let* ) = Result.bind and ( let+ ) x f = Result.map f x in