From 4e3e551753ac4764cf26843c85f5e666360d2403 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Mar 2023 06:56:51 +0000 Subject: [PATCH 1/3] build(deps): bump actions/checkout from 3.4.0 to 3.5.0 Bumps [actions/checkout](https://github.com/actions/checkout) from 3.4.0 to 3.5.0. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3.4.0...v3.5.0) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/deploy.yml | 4 ++-- .github/workflows/lint.yml | 6 +++--- .github/workflows/metadata-validation.yml | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 450c2601a..dc9472022 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -8,7 +8,7 @@ jobs: name: Build docs runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 - uses: actions/setup-python@v4.5.0 with: python-version: 3.x @@ -25,7 +25,7 @@ jobs: name: Deploy docs runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 with: fetch-depth: '0' - uses: actions/setup-python@v4.5.0 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 64d3d8b0b..7fb64dd87 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -7,7 +7,7 @@ jobs: editorconfig-checker: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 - name: editorconfig-checker run: | docker run --rm \ @@ -17,7 +17,7 @@ jobs: markdownlint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 - name: markdownlint run: | find "${GITHUB_WORKSPACE}" -name '*.md' -exec \ @@ -30,7 +30,7 @@ jobs: yamllint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 - name: yamllint run: | find "${GITHUB_WORKSPACE}" -name '*.yaml' -o -name '*.yml' -exec \ diff --git a/.github/workflows/metadata-validation.yml b/.github/workflows/metadata-validation.yml index b3bc1040c..8c1855752 100644 --- a/.github/workflows/metadata-validation.yml +++ b/.github/workflows/metadata-validation.yml @@ -17,7 +17,7 @@ jobs: runs-on: ubuntu-latest name: Validate metadata.json steps: - - uses: actions/checkout@v3.4.0 + - uses: actions/checkout@v3.5.0 - uses: actions/setup-python@v4.5.0 with: python-version: "3.x" From 77a279c77a9e4b5f27a188b0a099e436f64292fa Mon Sep 17 00:00:00 2001 From: Gabe Date: Mon, 27 Mar 2023 22:28:18 +0200 Subject: [PATCH 2/3] SABnzbd - Update replace_for.py to work with V.4.0.0 Sabnzbd Version 4.0.0 (current beta) introduced a couple of input variables, that weren't available in the versions before. This PR fixes the two scripts in the Guide, so they are compatible with earlier and V4+ versions https://sabnzbd.org/wiki/scripts/pre-queue-scripts#toc3 --- .../Downloaders/SABnzbd/scripts/replace_for/replace_for.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/Downloaders/SABnzbd/scripts/replace_for/replace_for.py b/docs/Downloaders/SABnzbd/scripts/replace_for/replace_for.py index d347394cf..0345f3650 100644 --- a/docs/Downloaders/SABnzbd/scripts/replace_for/replace_for.py +++ b/docs/Downloaders/SABnzbd/scripts/replace_for/replace_for.py @@ -20,7 +20,12 @@ import os import os.path try: - (scriptname, directory, orgnzbname, jobname, reportnumber, category, group, postprocstatus, url) = sys.argv + try: + # Parse the 18 input variables for SABnzbd version >= 4.0.0 + (scriptname, nzbname, postprocflags, category, script, prio, downloadsize, grouplist, showname, season, episodenumber, episodename, is_proper, resolution, decade, year, month, day, job_type) = sys.argv +except ValueError: + # ...or 11 variables for earlier versions + (scriptname, nzbname, postprocflags, category, script, prio, downloadsize, grouplist, showname, season, episodenumber, episodename) = sys.argv except: print("No commandline parameters found") sys.exit(1) # exit with 1 causes SABnzbd to ignore the output of this script From ddc7efac1569cc22e0a42701b8e7955dd04cd7f9 Mon Sep 17 00:00:00 2001 From: Gabe Date: Mon, 27 Mar 2023 22:29:35 +0200 Subject: [PATCH 3/3] SABnzbd - Update Clean.py to work with V.4.0.0 Sabnzbd Version 4.0.0 (current beta) introduced a couple of input variables, that weren't available in the versions before. This PR fixes the two scripts in the Guide, so they are compatible with earlier and V4+ versions https://sabnzbd.org/wiki/scripts/pre-queue-scripts#toc3 --- docs/Downloaders/SABnzbd/scripts/Clean/Clean.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/Downloaders/SABnzbd/scripts/Clean/Clean.py b/docs/Downloaders/SABnzbd/scripts/Clean/Clean.py index a7f13064a..060161642 100644 --- a/docs/Downloaders/SABnzbd/scripts/Clean/Clean.py +++ b/docs/Downloaders/SABnzbd/scripts/Clean/Clean.py @@ -21,8 +21,12 @@ import sys import re try: - (scriptname, nzbname, postprocflags, category, script, prio, downloadsize, grouplist, showname, season, episodenumber, episodename) = sys.argv + # Parse the 18 input variables for SABnzbd version >= 4.0.0 + (scriptname, nzbname, postprocflags, category, script, prio, downloadsize, grouplist, showname, season, episodenumber, episodename, is_proper, resolution, decade, year, month, day, job_type) = sys.argv downloadsize = int(downloadsize) +except ValueError: + # ...or 11 variables for earlier versions + (scriptname, nzbname, postprocflags, category, script, prio, downloadsize, grouplist, showname, season, episodenumber, episodename) = sys.argv except: sys.exit(1) # exit with 1 causes SABnzbd to ignore the output of this script @@ -64,4 +68,4 @@ print() print() print() # 0 means OK -sys.exit(0) \ No newline at end of file +sys.exit(0)