From 172b3e72a1b50f6c9c73186589e8f2960909a105 Mon Sep 17 00:00:00 2001 From: Dennis Reimann Date: Thu, 16 Jan 2025 17:24:44 +0100 Subject: [PATCH] Log connection error --- BTCPayApp.Core/BTCPayServer/BTCPayConnectionManager.cs | 5 +++++ README.md | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/BTCPayApp.Core/BTCPayServer/BTCPayConnectionManager.cs b/BTCPayApp.Core/BTCPayServer/BTCPayConnectionManager.cs index 0f962254..0f14d3cc 100644 --- a/BTCPayApp.Core/BTCPayServer/BTCPayConnectionManager.cs +++ b/BTCPayApp.Core/BTCPayServer/BTCPayConnectionManager.cs @@ -269,6 +269,11 @@ private async Task OnConnectionChanged(object? sender, (BTCPayConnectionState Ol break; } } + catch (Exception ex) + { + _logger.LogError(ex, "Error while changing connection state from {Old} to {New}", e.Old, e.New); + throw; + } finally { _ = Task.Run(() => ConnectionState = newState); diff --git a/README.md b/README.md index b25932f3..a62adb50 100644 --- a/README.md +++ b/README.md @@ -46,10 +46,10 @@ If BTCPay Server does not start up with the app and its dependencies, run this: ```bash cd BTCPayApp.Core -dotnet publish /p:RazorCompileOnBuild=true -o ../BTCPayServer.Plugins.App/bin/Debug/net8.0 +dotnet publish -c Debug -o ../BTCPayServer.Plugins.App/bin/Debug/net8.0 cd - cd BTCPayServer.Plugins.App -dotnet publish /p:RazorCompileOnBuild=true -o bin/Debug/net8.0 +dotnet publish -c Debug -o bin/Debug/net8.0 cd - ```