From 26ed68a83f1cef5946938695f1e460b315870814 Mon Sep 17 00:00:00 2001 From: kernelkind Date: Wed, 15 Jan 2025 16:56:14 -0500 Subject: [PATCH] log nip05 error Signed-off-by: kernelkind --- crates/notedeck_columns/src/key_parsing.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/crates/notedeck_columns/src/key_parsing.rs b/crates/notedeck_columns/src/key_parsing.rs index ae605c17..0b46724e 100644 --- a/crates/notedeck_columns/src/key_parsing.rs +++ b/crates/notedeck_columns/src/key_parsing.rs @@ -6,6 +6,7 @@ use ehttp::{Request, Response}; use enostr::{Keypair, Pubkey, SecretKey}; use poll_promise::Promise; use serde::{Deserialize, Serialize}; +use tracing::error; #[derive(Debug, PartialEq, Clone)] pub enum AcquireKeyError { @@ -104,7 +105,11 @@ fn nip05_promise_wrapper(id: &str) -> Promise> let result = original_promise.block_and_take(); let transformed_result = match result { Ok(public_key) => Ok(Keypair::only_pubkey(public_key)), - Err(e) => Err(AcquireKeyError::Nip05Failed(e.to_string())), + Err(e) => { + let error_msg = e.to_string(); + error!("Nip05 Failed: {}", error_msg); + Err(AcquireKeyError::Nip05Failed(error_msg)) + } }; sender.send(transformed_result); });