From bcf4fe9429f09efa2514489a6fb9bafec14f775e Mon Sep 17 00:00:00 2001 From: Dmitriy Khaustov Date: Tue, 10 Oct 2023 15:33:32 +0300 Subject: [PATCH] Fix zombienet test (#1840) * fix: false negative approval checking result Signed-off-by: Dmitriy Khaustov aka xDimon --- core/crypto/crypto_store/key_type.hpp | 2 +- core/parachain/approval/approval_distribution.cpp | 2 +- core/parachain/availability/recovery/recovery_impl.cpp | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/core/crypto/crypto_store/key_type.hpp b/core/crypto/crypto_store/key_type.hpp index 49b2159cc3..8bc433830f 100644 --- a/core/crypto/crypto_store/key_type.hpp +++ b/core/crypto/crypto_store/key_type.hpp @@ -18,7 +18,7 @@ namespace kagome::crypto { }; /** - * Makes 32bit integer uin which represent encoded 4-char strings + * Makes 32bit integer which represent encoded 4-char strings * Little-endian byte order is used */ constexpr uint32_t operator""_key(const char *s, std::size_t size) { diff --git a/core/parachain/approval/approval_distribution.cpp b/core/parachain/approval/approval_distribution.cpp index 71c3189c67..14c5d2378a 100644 --- a/core/parachain/approval/approval_distribution.cpp +++ b/core/parachain/approval/approval_distribution.cpp @@ -1289,7 +1289,7 @@ namespace kagome::parachain { self->logger_->warn( "Parachain data recovery failed.(error={}, session index={}, " "candidate hash={}, relay block hash={})", - opt_result->error().message(), + opt_result->error(), session_index, candidate_hash, relay_block_hash); diff --git a/core/parachain/availability/recovery/recovery_impl.cpp b/core/parachain/availability/recovery/recovery_impl.cpp index 7f6846c262..637c3de630 100644 --- a/core/parachain/availability/recovery/recovery_impl.cpp +++ b/core/parachain/availability/recovery/recovery_impl.cpp @@ -160,8 +160,7 @@ namespace kagome::parachain { } if (active.chunks.size() + active.chunks_active + active.order.size() < active.chunks_required) { - return done( - lock, it, toErasureCodingError(ec_cpp::Error::kNeedMoreShards)); + return done(lock, it, std::nullopt); } auto max = std::min(kParallelRequests, active.chunks_required - active.chunks.size());