diff --git a/waku/waku_archive/archive.nim b/waku/waku_archive/archive.nim index 435fb4e2eb..db642e3835 100644 --- a/waku/waku_archive/archive.nim +++ b/waku/waku_archive/archive.nim @@ -112,7 +112,10 @@ proc handleMessage*(w: WakuArchive, let putRes = await w.driver.put(pubsubTopic, msg, msgDigest, msgHash, msgReceivedTime) if putRes.isErr(): - error "failed to insert message", err=putRes.error + if "duplicate key value violates unique constraint" in putRes.error: + trace "failed to insert message", err=putRes.error + else: + debug "failed to insert message", err=putRes.error waku_archive_errors.inc(labelValues = [insertFailure]) let insertDuration = getTime().toUnixFloat() - insertStartTime