aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
authorLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2024-04-24 01:49:20 +0100
committerLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2024-04-24 01:49:20 +0100
commitb125bde9e4c8955fcfb6aae8ce9def13bfff726e (patch)
tree21a6cfedff69b7b8ab369e8f3cdf08432d9e456b /src
parent9ebbb9ee741c1d78a52789a646af83bce21e5a78 (diff)
downloadsentrum-b125bde9e4c8955fcfb6aae8ce9def13bfff726e.tar.gz
sentrum-b125bde9e4c8955fcfb6aae8ce9def13bfff726e.tar.bz2
sentrum-b125bde9e4c8955fcfb6aae8ce9def13bfff726e.zip
Use alt selector for displaying anyhow::Error
Diffstat (limited to 'src')
-rw-r--r--src/actions.rs2
-rw-r--r--src/actions/nostr.rs2
-rw-r--r--src/blockchain.rs2
-rw-r--r--src/main.rs2
-rw-r--r--src/wallets.rs6
5 files changed, 7 insertions, 7 deletions
diff --git a/src/actions.rs b/src/actions.rs
index b462102..7979bd7 100644
--- a/src/actions.rs
+++ b/src/actions.rs
@@ -115,7 +115,7 @@ pub async fn get_actions<'a>(
result.push(action);
}
Err(e) => {
- warn!("could not register action '{}': {}", action_config, e);
+ warn!("[{}] could not register action: {:#}", action_config, e);
}
}
}
diff --git a/src/actions/nostr.rs b/src/actions/nostr.rs
index 3507d2e..6ad91b5 100644
--- a/src/actions/nostr.rs
+++ b/src/actions/nostr.rs
@@ -156,7 +156,7 @@ impl<'a> NostrAction<'a> {
nip05::get_profile(&nostr_config.recipient, nostr_config.proxy)
.await
.with_context(|| {
- format!("invalid recipient '{}': {}", nostr_config.recipient, e)
+ format!("invalid recipient '{}': {:#}", nostr_config.recipient, e)
})?
.public_key
}
diff --git a/src/blockchain.rs b/src/blockchain.rs
index 92e585f..6deac8a 100644
--- a/src/blockchain.rs
+++ b/src/blockchain.rs
@@ -91,7 +91,7 @@ impl BlockchainState {
}
};
}
- Err(e) => warn!("could not reach '{}': {}", self.url, e),
+ Err(e) => warn!("could not reach '{}': {:#}", self.url, e),
};
}
}
diff --git a/src/main.rs b/src/main.rs
index 436bbdd..f719433 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -155,7 +155,7 @@ async fn do_main() -> Result<()> {
#[tokio::main]
async fn main() {
if let Err(e) = do_main().await {
- error!("{:?}", e);
+ error!("{:#}", e);
exit(1);
}
}
diff --git a/src/wallets.rs b/src/wallets.rs
index cc4f157..9ee702c 100644
--- a/src/wallets.rs
+++ b/src/wallets.rs
@@ -183,13 +183,13 @@ impl WalletInfo {
pub fn get_new_txs(&mut self) -> Vec<TransactionDetails> {
debug!("[{}] syncing wallet", self.name);
if let Err(e) = self.wallet.sync(&self.blockchain, SyncOptions::default()) {
- warn!("[{}] cannot sync wallet: {}", self.name, e);
+ warn!("[{}] cannot sync wallet: {:#}", self.name, e);
return Default::default();
}
let tx_list = match self.wallet.list_transactions(false) {
Ok(txs) => txs,
Err(e) => {
- warn!("[{}] cannot retrieve transactions: {}", self.name, e);
+ warn!("[{}] cannot retrieve transactions: {:#}", self.name, e);
Default::default()
}
};
@@ -223,7 +223,7 @@ pub fn get_wallets(
})));
}
Err(e) => {
- error!("[{}] cannot setup wallet: {}", name, e);
+ error!("[{}] cannot setup wallet: {:#}", name, e);
}
}
}