From e624e1657e7693c2a25650940194123a58bbecee Mon Sep 17 00:00:00 2001 From: Marcel Moura <5615598+marcelstanley@users.noreply.github.com> Date: Wed, 14 Aug 2024 16:45:37 -0300 Subject: [PATCH] chore(dispatcher): improve epoch-related logs --- CHANGELOG.md | 1 + offchain/dispatcher/src/drivers/context.rs | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 82b4df137..3ef42584b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed - server-manager failures treated as errors on inspect-server. +- Improved dispatcher logs. ## [1.5.0] 2024-07-22 diff --git a/offchain/dispatcher/src/drivers/context.rs b/offchain/dispatcher/src/drivers/context.rs index 04180ea5a..09ff490a2 100644 --- a/offchain/dispatcher/src/drivers/context.rs +++ b/offchain/dispatcher/src/drivers/context.rs @@ -134,7 +134,9 @@ impl Context { (Some(_), None) => true, // Consider input_epoch greater than None (None, _) => false, // None is never greater than any value }, - "Assertion failed: last_input_epoch should be greater than last_finished_epoch" + "cannot finish epoch: last_input_epoch ({:?}) is not greater than last_finished_epoch ({:?})", + self.last_input_epoch, + self.last_finished_epoch ); broker.finish_epoch(self.inputs_sent).await?;