From b8b530531ee76936dc368e05ee59100ec85efc62 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Mon, 29 Dec 2025 11:28:56 +0100 Subject: [PATCH 1/3] Updated Packages to fix errors in logs that appears --- .github/workflows/dotnet.yml | 2 +- iGotify Notification Assist.csproj | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 5063b28..c3c4601 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -114,7 +114,7 @@ jobs: build-project: - if: github.event.pull_request.merged == true + #if: github.event.pull_request.merged == true name: Build dotNet strategy: matrix: diff --git a/iGotify Notification Assist.csproj b/iGotify Notification Assist.csproj index 389b8a9..e53ab25 100644 --- a/iGotify Notification Assist.csproj +++ b/iGotify Notification Assist.csproj @@ -15,11 +15,11 @@ - - + + - - + + From 23aa7f629d4fa04c60d91d4e0cd9a26c227b95c1 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Mon, 29 Dec 2025 16:54:07 +0100 Subject: [PATCH 2/3] Updated Lib and Fixes - updated secntfy nuget to 1.0.8 and made it async/await - bump version to 1.5.1.3 - fixed #214 --- .github/workflows/dotnet.yml | 2 +- Services/GotifySocketService.cs | 8 ++++---- iGotify Notification Assist.csproj | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index c3c4601..8356db9 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -118,7 +118,7 @@ jobs: name: Build dotNet strategy: matrix: - dotnet-version: [ '9.x' ] + dotnet-version: [ '10.x' ] kind: [ 'amd64', 'arm64', 'armv7' ] include: - kind: amd64 diff --git a/Services/GotifySocketService.cs b/Services/GotifySocketService.cs index a261973..1e0d112 100644 --- a/Services/GotifySocketService.cs +++ b/Services/GotifySocketService.cs @@ -261,7 +261,7 @@ public async void Start() var statusNtfyList = secntfyTokenList.Count == 0 ? "empty" : "filled"; Console.WriteLine($"SecNtfy Token list is: {statusNtfyList}"); Console.WriteLine( - $"If one or more lists are empty please check the environment variable! GOTIFY_SERVERS or GOTIFY_CLIENTS or NTFY_TOKENS"); + $"If one or more lists are empty please check the environment variable! GOTIFY_URLS or GOTIFY_CLIENT_TOKENS or SECNTFY_TOKENS"); Console.WriteLine( $"If all lists are empty do nothing, you will configure the gotify server over the iGotify app."); } @@ -271,7 +271,7 @@ public async void Start() StartConnection(userList, secntfyUrl); } - private void StartConnection(List userList, string secntfyUrl) + private async void StartConnection(List userList, string secntfyUrl) { foreach (var user in userList) { @@ -279,7 +279,7 @@ private void StartConnection(List userList, string secntfyUrl) string isSecNtfyAvailable; try { - isGotifyAvailable = SecNtfy.CheckIfUrlReachable(user.GotifyUrl) ? "yes" : "no"; + isGotifyAvailable = await SecNtfy.CheckIfUrlReachable(user.GotifyUrl) ? "yes" : "no"; if (isGotifyAvailable == "no") { @@ -296,7 +296,7 @@ private void StartConnection(List userList, string secntfyUrl) try { - bool isSecNtfyAvailableBool = SecNtfy.CheckIfUrlReachable(secntfyUrl); + bool isSecNtfyAvailableBool = await SecNtfy.CheckIfUrlReachable(secntfyUrl); isSecNtfyAvailable = isSecNtfyAvailableBool ? "yes" : "no"; if (!isSecNtfyAvailableBool) diff --git a/iGotify Notification Assist.csproj b/iGotify Notification Assist.csproj index e53ab25..ba4886d 100644 --- a/iGotify Notification Assist.csproj +++ b/iGotify Notification Assist.csproj @@ -6,9 +6,9 @@ enable true iGotify_Notification_Assist - 1.5.1.2 - 1.5.1.2 - 1.5.1.2 + 1.5.1.3 + 1.5.1.3 + 1.5.1.3 default @@ -19,7 +19,7 @@ - + From 2399d3b3a1086599a6334ec3fd7f848aa3de4936 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Tue, 30 Dec 2025 00:42:31 +0100 Subject: [PATCH 3/3] Updated Nuget - Updated Nuget - cleared Output from sending notification --- Models/DeviceModel.cs | 3 ++- iGotify Notification Assist.csproj | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Models/DeviceModel.cs b/Models/DeviceModel.cs index 366708b..b08be2d 100644 --- a/Models/DeviceModel.cs +++ b/Models/DeviceModel.cs @@ -1,4 +1,5 @@ using iGotify_Notification_Assist.Services; +using Newtonsoft.Json; using SecNtfyNuGet; using Websocket.Client; using Environments = iGotify_Notification_Assist.Services.Environments; @@ -59,6 +60,6 @@ public async Task SendNotifications(GotifyMessage iGotifyMessage, WebsocketClien var ntfy = new SecNtfy(Environments.secNtfyUrl); var response = await ntfy.SendNotification(usr.DeviceToken, title, msg, iGotifyMessage.priority == 10, imageUrl, iGotifyMessage.priority); - Console.WriteLine(response); + Console.WriteLine(response != null ? JsonConvert.SerializeObject(response) : "Notification response is null"); } } \ No newline at end of file diff --git a/iGotify Notification Assist.csproj b/iGotify Notification Assist.csproj index ba4886d..a2ea6c5 100644 --- a/iGotify Notification Assist.csproj +++ b/iGotify Notification Assist.csproj @@ -19,7 +19,7 @@ - +