From 2e8b896f3ba03d8edd6c481e51f8b186f9b8b6e6 Mon Sep 17 00:00:00 2001 From: Glax Date: Sat, 27 Apr 2024 17:53:08 +0200 Subject: [PATCH 1/5] Fix #178 wrong check on parsing variable aprilfoolsmode --- Tranga/Server.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tranga/Server.cs b/Tranga/Server.cs index 77e2fba..bef0941 100644 --- a/Tranga/Server.cs +++ b/Tranga/Server.cs @@ -410,7 +410,7 @@ public class Server : GlobalBase break; case "Settings/AprilFoolsMode": if (!requestVariables.TryGetValue("enabled", out string? aprilFoolsModeEnabledStr) || - bool.TryParse(aprilFoolsModeEnabledStr, out bool aprilFoolsModeEnabled)) + !bool.TryParse(aprilFoolsModeEnabledStr, out bool aprilFoolsModeEnabled)) { SendResponse(HttpStatusCode.BadRequest, response); break; From e05684d5d13335e5c0d869430a0f46639f42b45c Mon Sep 17 00:00:00 2001 From: Glax Date: Sun, 26 May 2024 18:22:51 +0200 Subject: [PATCH 2/5] Fix loading file results in "null"-job and crashes. --- Tranga/Jobs/JobBoss.cs | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/Tranga/Jobs/JobBoss.cs b/Tranga/Jobs/JobBoss.cs index 275864b..c8cd28b 100644 --- a/Tranga/Jobs/JobBoss.cs +++ b/Tranga/Jobs/JobBoss.cs @@ -151,10 +151,19 @@ public class JobBoss : GlobalBase foreach (FileInfo file in new DirectoryInfo(settings.jobsFolderPath).EnumerateFiles().Where(fileInfo => idRex.IsMatch(fileInfo.Name))) { Log($"Adding {file.Name}"); - Job job = JsonConvert.DeserializeObject(File.ReadAllText(file.FullName), - new JobJsonConverter(this, new MangaConnectorJsonConverter(this, connectors)))!; - Log($"Adding Job {job}"); - this.jobs.Add(job); + Job? job = JsonConvert.DeserializeObject(File.ReadAllText(file.FullName), + new JobJsonConverter(this, new MangaConnectorJsonConverter(this, connectors))); + if (job is null) + { + string newName = file.FullName + ".failed"; + Log($"Failed loading file {file.Name}.\nMoving to {newName}"); + File.Move(file.FullName, newName); + } + else + { + Log($"Adding Job {job}"); + this.jobs.Add(job); + } } //Connect jobs to parent-jobs and add Publications to cache From 4a4fe4b40d8fbed94f5dbcef8f8844f0ab43cc30 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Jul 2024 05:56:42 +0000 Subject: [PATCH 3/5] Bump docker/setup-qemu-action from 2.2.0 to 3.1.0 Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 2.2.0 to 3.1.0. - [Release notes](https://github.com/docker/setup-qemu-action/releases) - [Commits](https://github.com/docker/setup-qemu-action/compare/v2.2.0...v3.1.0) --- updated-dependencies: - dependency-name: docker/setup-qemu-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-base.yml | 2 +- .github/workflows/docker-image-cuttingedge.yml | 2 +- .github/workflows/docker-image-dev.yml | 2 +- .github/workflows/docker-image-master.yml | 2 +- .github/workflows/docker-image-serverv2.yml | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/docker-base.yml b/.github/workflows/docker-base.yml index 00d8293..d69c628 100644 --- a/.github/workflows/docker-base.yml +++ b/.github/workflows/docker-base.yml @@ -15,7 +15,7 @@ jobs: # https://github.com/docker/setup-qemu-action#usage - name: Set up QEMU - uses: docker/setup-qemu-action@v2.2.0 + uses: docker/setup-qemu-action@v3.1.0 # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx diff --git a/.github/workflows/docker-image-cuttingedge.yml b/.github/workflows/docker-image-cuttingedge.yml index bd6a1e6..7c85338 100644 --- a/.github/workflows/docker-image-cuttingedge.yml +++ b/.github/workflows/docker-image-cuttingedge.yml @@ -17,7 +17,7 @@ jobs: # https://github.com/docker/setup-qemu-action#usage - name: Set up QEMU - uses: docker/setup-qemu-action@v2.2.0 + uses: docker/setup-qemu-action@v3.1.0 # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx diff --git a/.github/workflows/docker-image-dev.yml b/.github/workflows/docker-image-dev.yml index 40b59e8..29ab5f8 100644 --- a/.github/workflows/docker-image-dev.yml +++ b/.github/workflows/docker-image-dev.yml @@ -17,7 +17,7 @@ jobs: # https://github.com/docker/setup-qemu-action#usage - name: Set up QEMU - uses: docker/setup-qemu-action@v2.2.0 + uses: docker/setup-qemu-action@v3.1.0 # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx diff --git a/.github/workflows/docker-image-master.yml b/.github/workflows/docker-image-master.yml index 4c9085d..ccb49b0 100644 --- a/.github/workflows/docker-image-master.yml +++ b/.github/workflows/docker-image-master.yml @@ -17,7 +17,7 @@ jobs: # https://github.com/docker/setup-qemu-action#usage - name: Set up QEMU - uses: docker/setup-qemu-action@v2.2.0 + uses: docker/setup-qemu-action@v3.1.0 # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx diff --git a/.github/workflows/docker-image-serverv2.yml b/.github/workflows/docker-image-serverv2.yml index 108073c..45da39b 100644 --- a/.github/workflows/docker-image-serverv2.yml +++ b/.github/workflows/docker-image-serverv2.yml @@ -17,7 +17,7 @@ jobs: # https://github.com/docker/setup-qemu-action#usage - name: Set up QEMU - uses: docker/setup-qemu-action@v2.2.0 + uses: docker/setup-qemu-action@v3.1.0 # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx From e15c6816b59b3ba7a985c5a335712064404e92f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Jul 2024 05:56:47 +0000 Subject: [PATCH 4/5] Bump docker/build-push-action from 6.1.0 to 6.3.0 Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 6.1.0 to 6.3.0. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](https://github.com/docker/build-push-action/compare/v6.1.0...v6.3.0) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-base.yml | 2 +- .github/workflows/docker-image-cuttingedge.yml | 2 +- .github/workflows/docker-image-dev.yml | 2 +- .github/workflows/docker-image-master.yml | 2 +- .github/workflows/docker-image-serverv2.yml | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/docker-base.yml b/.github/workflows/docker-base.yml index 00d8293..df3c728 100644 --- a/.github/workflows/docker-base.yml +++ b/.github/workflows/docker-base.yml @@ -31,7 +31,7 @@ jobs: # https://github.com/docker/build-push-action#multi-platform-image - name: Build and push base - uses: docker/build-push-action@v6.1.0 + uses: docker/build-push-action@v6.3.0 with: context: ./ file: ./Dockerfile-base diff --git a/.github/workflows/docker-image-cuttingedge.yml b/.github/workflows/docker-image-cuttingedge.yml index bd6a1e6..93679f9 100644 --- a/.github/workflows/docker-image-cuttingedge.yml +++ b/.github/workflows/docker-image-cuttingedge.yml @@ -33,7 +33,7 @@ jobs: # https://github.com/docker/build-push-action#multi-platform-image - name: Build and push API - uses: docker/build-push-action@v6.1.0 + uses: docker/build-push-action@v6.3.0 with: context: ./ file: ./Dockerfile diff --git a/.github/workflows/docker-image-dev.yml b/.github/workflows/docker-image-dev.yml index 40b59e8..9fc87f0 100644 --- a/.github/workflows/docker-image-dev.yml +++ b/.github/workflows/docker-image-dev.yml @@ -33,7 +33,7 @@ jobs: # https://github.com/docker/build-push-action#multi-platform-image - name: Build and push API - uses: docker/build-push-action@v6.1.0 + uses: docker/build-push-action@v6.3.0 with: context: ./ file: ./Dockerfile diff --git a/.github/workflows/docker-image-master.yml b/.github/workflows/docker-image-master.yml index 4c9085d..0c7a085 100644 --- a/.github/workflows/docker-image-master.yml +++ b/.github/workflows/docker-image-master.yml @@ -33,7 +33,7 @@ jobs: # https://github.com/docker/build-push-action#multi-platform-image - name: Build and push API - uses: docker/build-push-action@v6.1.0 + uses: docker/build-push-action@v6.3.0 with: context: ./ file: ./Dockerfile diff --git a/.github/workflows/docker-image-serverv2.yml b/.github/workflows/docker-image-serverv2.yml index 108073c..ba542ce 100644 --- a/.github/workflows/docker-image-serverv2.yml +++ b/.github/workflows/docker-image-serverv2.yml @@ -33,7 +33,7 @@ jobs: # https://github.com/docker/build-push-action#multi-platform-image - name: Build and push API - uses: docker/build-push-action@v6.1.0 + uses: docker/build-push-action@v6.3.0 with: context: ./ file: ./Dockerfile From d60ed77dbeac9eea6657264fafea2c7655045426 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Jul 2024 05:11:09 +0000 Subject: [PATCH 5/5] Bump docker/setup-buildx-action from 3.3.0 to 3.4.0 Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 3.3.0 to 3.4.0. - [Release notes](https://github.com/docker/setup-buildx-action/releases) - [Commits](https://github.com/docker/setup-buildx-action/compare/v3.3.0...v3.4.0) --- updated-dependencies: - dependency-name: docker/setup-buildx-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-base.yml | 2 +- .github/workflows/docker-image-cuttingedge.yml | 2 +- .github/workflows/docker-image-dev.yml | 2 +- .github/workflows/docker-image-master.yml | 2 +- .github/workflows/docker-image-serverv2.yml | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/docker-base.yml b/.github/workflows/docker-base.yml index 00d8293..794c685 100644 --- a/.github/workflows/docker-base.yml +++ b/.github/workflows/docker-base.yml @@ -20,7 +20,7 @@ jobs: # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@v3.3.0 + uses: docker/setup-buildx-action@v3.4.0 # https://github.com/docker/login-action#docker-hub - name: Login to Docker Hub diff --git a/.github/workflows/docker-image-cuttingedge.yml b/.github/workflows/docker-image-cuttingedge.yml index bd6a1e6..42e4392 100644 --- a/.github/workflows/docker-image-cuttingedge.yml +++ b/.github/workflows/docker-image-cuttingedge.yml @@ -22,7 +22,7 @@ jobs: # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@v3.3.0 + uses: docker/setup-buildx-action@v3.4.0 # https://github.com/docker/login-action#docker-hub - name: Login to Docker Hub diff --git a/.github/workflows/docker-image-dev.yml b/.github/workflows/docker-image-dev.yml index 40b59e8..a3e77f0 100644 --- a/.github/workflows/docker-image-dev.yml +++ b/.github/workflows/docker-image-dev.yml @@ -22,7 +22,7 @@ jobs: # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@v3.3.0 + uses: docker/setup-buildx-action@v3.4.0 # https://github.com/docker/login-action#docker-hub - name: Login to Docker Hub diff --git a/.github/workflows/docker-image-master.yml b/.github/workflows/docker-image-master.yml index 4c9085d..b788127 100644 --- a/.github/workflows/docker-image-master.yml +++ b/.github/workflows/docker-image-master.yml @@ -22,7 +22,7 @@ jobs: # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@v3.3.0 + uses: docker/setup-buildx-action@v3.4.0 # https://github.com/docker/login-action#docker-hub - name: Login to Docker Hub diff --git a/.github/workflows/docker-image-serverv2.yml b/.github/workflows/docker-image-serverv2.yml index 108073c..e9596c0 100644 --- a/.github/workflows/docker-image-serverv2.yml +++ b/.github/workflows/docker-image-serverv2.yml @@ -22,7 +22,7 @@ jobs: # https://github.com/marketplace/actions/docker-setup-buildx - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@v3.3.0 + uses: docker/setup-buildx-action@v3.4.0 # https://github.com/docker/login-action#docker-hub - name: Login to Docker Hub