10043 Commits

Author SHA1 Message Date
Safihre
92489bb624 Configure Renovate to track Python and sabctools versions
Adds custom managers to allow Renovate to detect and propose updates for the Python version used in the build workflow and the `SABCTOOLS_VERSION_REQUIRED` constant. Removes `sabctools` from the ignore list to enable these updates.
2026-06-07 13:03:03 +02:00
Safihre
fa982d4f69 Update macOS build Python to 3.14.5 2026-06-07 12:42:59 +02:00
SABnzbd Automation
64f55c0834 Update translatable texts
[skip ci]
2026-06-07 06:43:44 +00:00
mnightingale
babd8517e9 Database SQLite storage for RSS feeds (#3253)
* Store RSS in database

* Use context manager for rss repository in most instances

* Combine _evaluate_entry and _process_entry
2026-06-07 08:43:14 +02:00
Safihre
0950393b82 Correctly format tests based on new rules and remove star imports 2026-06-05 14:34:17 +02:00
Safihre
08bcddf8d2 Style login and wizard pages after recent changes 2026-06-05 14:32:04 +02:00
Safihre
eae5f164e6 Correct rounding of the Warnings box 2026-06-05 10:39:07 +02:00
Safihre
d5700bf8a3 Apply C4 linter rules for collection usage
Refactors collection initializations and comprehensions to use more concise and idiomatic Python syntax, such as set literals (`{...}`) instead of `set([...])`, empty dictionary literals (`{}`) instead of `dict()`, and `dict.fromkeys` for `str.maketrans`.
Also removes unnecessary list creation within `any()` calls.
2026-06-05 09:04:05 +02:00
Safihre
d969d3df1a Skip File Rename When Paths Are Identical
Adds an explicit check to prevent unnecessary rename operations when the target path is the same as the original file's path. This provides clearer debug logging and avoids redundant filesystem calls.

Closes #3449, #3442
2026-06-04 13:59:40 +02:00
Safihre
5e3126cd14 Define NzoInfo with TypedDict
Explicitly defines the structure and types for the `nzo_info` dictionary.

Also introduces `BadArticleType` as a `Literal` type and cleans up
`__init__.py` by removing internal saver classes from the public API.
2026-06-04 12:48:05 +02:00
Safihre
f3ef46e5c2 Add concurrency control to translations workflow
Cancel in-progress runs on the same branch to prevent redundant executions and conserve resources.
2026-06-04 11:08:31 +02:00
mnightingale
ca5e02f2f1 Sanitise host_whitelist and login/request public IP addresses (#3437)
* Sanitise host_whitelist and login/request IP addresses

* Keep json keys

* Remove all IPv4 and IPv6 from logs

* Less crazy remote label replacements

* Remove unused import

* Sanitise public ipv4/ipv6 and test

* Add loopback/link-local test cases

* Switch is_local_addr to is_lan_addr because the former allows user configuration of trusted addresses

* Remove prefix group, ip regex should be good enough
2026-06-04 11:06:07 +02:00
renovate[bot]
dc870495c5 Update all dependencies (#3448)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-06-04 11:05:39 +02:00
VisorCraft
a6491750f7 Fix false "not writable" warning from non-atomic writability self-test (#3446)
directory_is_writable_with_file() removed its fixed-name temp file in a
non-atomic exists/remove/open/remove sequence wrapped in a blanket
"except Exception: return False". If the test file was removed between the
write and the final os.remove (e.g. by a concurrent writability check), the
FileNotFoundError was swallowed and reported as "is not writable at all.
This blocks downloads." -- a false negative on a fully writable folder.

Make the result depend only on creating and writing the file; treat cleanup
as best-effort. Genuine write failures still return False, and the unicode
and special-character capability checks are unchanged.

Adds regression tests for the cleanup race and for a genuine write failure.
2026-06-04 10:50:45 +02:00
mnightingale
6dacc71cb4 Add guards to blocking connections to prevent them processing the queue (#3444) 2026-06-04 10:48:48 +02:00
thezoggy
23c00b571c unrar 7.22 (#3447) 2026-06-03 10:02:02 +02:00
SABnzbd Automation
cc61dc974b Update translatable texts
[skip ci]
2026-05-26 14:54:59 +00:00
mnightingale
7f421a3c0b Add logging of unhandled connection exceptions and wait_for result (#3440) 2026-05-26 16:54:19 +02:00
Safihre
2740ad20b6 Enable lazy evaluation of type hints in decorators
Addresses a runtime error encountered when using native union syntax (PEP 604) with `threading.Lock` and `RLock` in type hints. As factory functions, they cannot be directly used with `|` without `from __future__ import annotations`.
2026-05-26 16:54:05 +02:00
Safihre
57e371aba5 Pin tempora to 5.8.1
Tempora 5.9.0 introduced an incompatibility with jaraco.classes that caused issues. Downgrade to the previous stable version and prevent Renovate from automatically updating it again.
Closes #3441
2026-05-26 16:45:58 +02:00
Safihre
c1096dc0ab Update type hints to use native union syntax and TypeAlias
Migrate to `A | B` syntax for unions (PEP 604) and introduce `typing.TypeAlias` for complex types, leveraging features available in Python 3.10+. This also updates `socket.timeout` to `TimeoutError` and adds `UP045` to Ruff ignores.
2026-05-26 16:44:49 +02:00
Safihre
08bdd12298 Enable slots for dataclasses
For improved performance. New in Python 3.10
2026-05-26 15:54:36 +02:00
Safihre
7b2e139e45 Update ruff target Python version to 3.10 2026-05-26 15:54:35 +02:00
renovate[bot]
1ce1440df8 Update all dependencies (#3436)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-05-26 15:53:21 +02:00
cardpuncher
a7c897f2ad Add French & Turkish translations to appdata.xml (#3439)
Validation still passing:
$ appstreamcli validate --pedantic org.sabnzbd.sabnzbd.appdata.xml
✔ Validation was successful.
2026-05-26 14:38:21 +02:00
Safihre
a344726c68 Drop support for Python 3.9
Luckily no Ubuntu LTS versions uses it!
https://documentation.ubuntu.com/ubuntu-for-developers/reference/availability/python/
2026-05-26 14:34:19 +02:00
Safihre
b0c31c7e10 Pin tempora for Python 3.9 2026-05-26 09:50:46 +02:00
mnightingale
2c530fee47 Remove disableDelays because config is not defined (#3438) 2026-05-26 06:50:24 +02:00
Ryan Hollister
25d20f0f08 Fix RuntimeError: dictionary changed size during iteration in stop_idle_jobs (#3432)
* Fix RuntimeError from dict mutation in stop_idle_jobs (#3431)

Collecting exhausted articles into a snapshot list while holding
nzf.lock, then calling register_article outside the iteration.
This prevents RuntimeError when register_article -> nzf.remove_article
pops from nzf.articles (a dict) while stop_idle_jobs is iterating it.

The original code in fd3ece31c used `nzf.articles[:]` which was safe
when articles was a list. When 44d94226e changed articles to a dict
the protective copy was dropped, leaving bare dict iteration that
mutates mid-loop.

The collect-then-act pattern matches nzf_remove_list in nzb/object.py
and the empty-nzo list already used in stop_idle_jobs itself. It also
correctly calls register_article outside nzf.lock, consistent with its
own "not locked for performance" contract.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* Apply Black formatting to nzbqueue.py

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* Soften comment per maintainer feedback

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-23 22:33:14 +02:00
SABnzbd Automation
3aaebed274 Update translatable texts
[skip ci]
2026-05-23 20:20:13 +00:00
Safihre
f12725eea5 Adjust new rounded UI layout and spacing for consistency
Refines margins, paddings, and element positioning across various components to improve visual harmony and alignment with the modernized interface design.
2026-05-23 22:17:28 +02:00
Safihre
dbf8ef15ef Refactor theming to use CSS variables
This modernizes the theming architecture by defining core colors as CSS variables,
allowing themes like 'Night' to override them concisely. This approach improves
maintainability and removes dynamic styling previously handled by JavaScript.
2026-05-23 22:05:46 +02:00
Safihre
de5abc95f5 Further improvements to styling revamp 2026-05-23 22:05:45 +02:00
Safihre
04379e3faa Change main interface to more rounded version 2026-05-23 22:05:45 +02:00
mnightingale
fec57377db Fix warnings when retrying jobs that have missing renamed files and fix the causes (#3428) 2026-05-23 18:59:44 +02:00
mnightingale
2f4750f77d Match previous RSS parsing behaviour (#3425)
* Match to previous RSS behaviour

* Cleanup logic due to normalisation

* Tests comparing 4.5.5 outcome

* Remove comment - fixed since 4.5.5

* Consistent types for prio, rule, season, and episode

* Rename matching_rule_index

* Fix type warnings
2026-05-22 22:34:30 +02:00
SABnzbd Automation
820442bdbd Update translatable texts
[skip ci]
2026-05-21 08:06:58 +00:00
Safihre
e63648c9c4 Give the Config a little bit more modern feeling 2026-05-21 10:06:01 +02:00
Safihre
a8751c5e77 Add extra logging when removing Movie category 2026-05-18 15:22:05 +02:00
renovate[bot]
196a92550c Update all dependencies (#3422)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-05-18 09:12:28 +02:00
SABnzbd Automation
526fcd3544 Update translatable texts
[skip ci]
2026-05-18 07:08:02 +00:00
Safihre
f817e4f0fb Work around pyproject.toml handling in snap build
The Python plugin attempts to `pip install -U .` when `pyproject.toml`
is present. As SABnzbd is an application source tree and not a
pip-installable package, this temporarily hides `pyproject.toml`
during the build step to prevent an incorrect installation attempt.
2026-05-18 09:07:20 +02:00
mnightingale
d7ca91e395 Try to clean the cache dir multiple times (#3419) 2026-05-16 22:43:07 +02:00
SABnzbd Automation
e3c8d79dae Update translatable texts
[skip ci]
2026-05-16 14:16:43 +00:00
Safihre
2cb472f690 Allow setting options for URL-grabbing jobs
And correct mistake in priority-API field, which was 0 (int) instead of "Normal" fallback.
2026-05-16 16:15:43 +02:00
Safihre
caee1d3bfe Front-end would show job with invalid date as URL-fetching
Closes #3418
2026-05-16 14:49:12 +02:00
Safihre
8069361faa Replace unreliable directory access check
The `os.access()` function can produce false negatives for directory writability, particularly in environments like NFS with UID mapping or root-squashing.

This change replaces the `os.access()` call with a direct I/O test (creating and deleting a temporary file) to ensure accurate and reliable verification of directory permissions.
2026-05-15 21:41:16 +02:00
Safihre
02c567fd8c Use reduced progress bar width in compact layout
Apply the table-header-progress-smaller class (25% width) to both queue and
history when compact layout is enabled, matching the behavior when extra columns
are shown. This provides more horizontal space for longer NZB titles.

Fixes #3414
2026-05-15 21:10:16 +02:00
Safihre
60f555117c Limit GitHub Actions workflow concurrency
Configures `concurrency` for the build, snap, and integration testing workflows. This prevents multiple concurrent runs of the same workflow on the same branch and automatically cancels older, in-progress runs when a new one is triggered.
2026-05-15 16:26:27 +02:00
Safihre
f259e47110 URLGrabber would crash on new installs
Closes #3417
2026-05-15 14:45:01 +02:00