From 1d0a198748c0e4aa1ce22ab2989a2b734f7d8948 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 27 Nov 2024 11:50:58 +0200 Subject: Ensure all exceptions are handled in build_*() notifications --- mod/mod-ci-github-gq.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'mod/mod-ci-github-gq.cxx') diff --git a/mod/mod-ci-github-gq.cxx b/mod/mod-ci-github-gq.cxx index a0a0d6b..7b7e464 100644 --- a/mod/mod-ci-github-gq.cxx +++ b/mod/mod-ci-github-gq.cxx @@ -521,9 +521,11 @@ namespace brep os << '\n'; os << " startedAt: " << gq_str (gh_to_iso8601 (*sa)); } - catch (const runtime_error& e) + catch (const system_error& e) { - throw invalid_argument ("invalid started_at value " + + // Translate for simplicity. + // + throw invalid_argument ("unable to convert started_at value " + to_string (system_clock::to_time_t (*sa)) + ": " + e.what ()); } -- cgit v1.1