From f1ac39f94c293a4c631b7e6390bfaed63beae5f1 Mon Sep 17 00:00:00 2001 From: davotoula Date: Fri, 1 May 2026 09:43:57 +0200 Subject: [PATCH] fix(zaps): downgrade "Zap Request not found" log from error to debug MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Receipts (kind 9735) frequently arrive before their matching zap-request (kind 9734) is in LocalCache when we are subscribed to receipt relays but not the zapper's outbox. That race is expected and not actionable from a user's perspective, yet the previous Log.e wrote a full stack-aiding error line — including the entire receipt JSON — to logcat for every unmatched receipt, often six or more times per id within a 15s window. Downgrade to Log.d so the message stays available for debugging while no longer flooding error logs in production benchmark runs. Co-Authored-By: Claude Opus 4.7 (1M context) --- .../main/java/com/vitorpamplona/amethyst/model/LocalCache.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/amethyst/src/main/java/com/vitorpamplona/amethyst/model/LocalCache.kt b/amethyst/src/main/java/com/vitorpamplona/amethyst/model/LocalCache.kt index 9dee631e8..f6bfbb53a 100644 --- a/amethyst/src/main/java/com/vitorpamplona/amethyst/model/LocalCache.kt +++ b/amethyst/src/main/java/com/vitorpamplona/amethyst/model/LocalCache.kt @@ -1673,7 +1673,7 @@ object LocalCache : ILocalCache, ICacheProvider { val zapRequest = event.zapRequest?.id?.let { getNoteIfExists(it) } if (zapRequest == null || zapRequest.event !is LnZapRequestEvent) { - Log.e("ZP") { "Zap Request not found. Unable to process Zap {${event.toJson()}}" } + Log.d("ZP") { "Zap Request not found. Unable to process Zap {${event.toJson()}}" } return false }