diff --git a/CHANGELOG.md b/CHANGELOG.md index f65e00d..50094be 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 0.54.18 - 2026-10-18 + +- Added a Queue page size selector beside Previous and Next with 10, 25, 50, and 100 items per page. The queue API now accepts up to 100 items per page. +- Added per-watchlist bulk refresh selection in Config → Watchlist management. Manual and scheduled refreshes use the same saved selection; Watching and Planned are enabled by default. Custom lists are supported, and selecting none refreshes no entries. +- Checked bundled anime providers against upstream; no updates were available. + ## 0.54.17 - 2026-10-17 - Fixed Jellyfin handoff skipping completed Tokyo Revengers seasons whose AnimeSchedule metadata was missing because of `(Uncensored)` or `[Uncensored]` title labels. Metadata matching now ignores release labels while preserving season and part identity. diff --git a/README.md b/README.md index cbf6330..6715098 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,8 @@ npm ci Keep **`.kaizoku/`**, `backup/`, downloads, and Jellyfin library folders when updating. `.kaizoku/` contains configuration, watchlists, queue history, and other persistent state. +On the Queue page, choose 10, 25, 50, or 100 items per page beside the Previous and Next buttons. In **Config → Watchlist management**, use each list's **Refresh** checkbox to choose which lists are included in manual and scheduled bulk refreshes, then save the configuration. Watching and Planned are selected by default; custom lists can also be selected. + ## Documentation See the **[Kaizoku wiki](https://gitea.coreplay.eu/Dymas/kaizoku/wiki)** for detailed instructions: @@ -43,6 +45,6 @@ See the **[Kaizoku wiki](https://gitea.coreplay.eu/Dymas/kaizoku/wiki)** for det - [Data safety](https://gitea.coreplay.eu/Dymas/kaizoku/wiki/Data-Safety) - [Providers and upstream versions](https://gitea.coreplay.eu/Dymas/kaizoku/wiki/Providers) -Provider parsers are adapted from [TheYogMehta/extensions](https://github.com/TheYogMehta/extensions). Bundled versions are Anikoto **6.0.0**, AniNeko **4.0.0**, and AnimePahe **6.0.1**, checked on 2026-10-17. Anikoto retains Kaizoku search, dub detection, and stream patches; AnimePahe uses only the official `.pw`, `.com`, and `.org` mirrors with bounded search retries and bridge-compatible logging. Upstream hooks that require StrawVerse's browser or mapping database are inactive in Kaizoku. +Provider parsers are adapted from [TheYogMehta/extensions](https://github.com/TheYogMehta/extensions). Bundled versions are Anikoto **6.0.0**, AniNeko **4.0.0**, and AnimePahe **6.0.1**, checked on 2026-10-18. Anikoto retains Kaizoku search, dub detection, and stream patches; AnimePahe uses only the official `.pw`, `.com`, and `.org` mirrors with bounded search retries and bridge-compatible logging. Upstream hooks that require StrawVerse's browser or mapping database are inactive in Kaizoku. -Live checks on that date returned Anikoto search results; AniNeko returned no matches and all three AnimePahe mirrors returned HTTP 403 from the test host. Current provider code does not guarantee source availability. Kaizoku does not host media. +Live source checks on 2026-10-17 returned Anikoto search results; AniNeko returned no matches and all three AnimePahe mirrors returned HTTP 403 from the test host. Current provider code does not guarantee source availability. Kaizoku does not host media. diff --git a/VERSION b/VERSION index a385648..d7193a7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.54.17 +0.54.18 diff --git a/app.py b/app.py index 9a52e03..3a3ee6a 100644 --- a/app.py +++ b/app.py @@ -2186,6 +2186,8 @@ class WatchlistStore: if normalized not in normalized_categories: normalized_categories.append(normalized) with self.lock, self._connect() as conn: + if categories is not None and not normalized_categories: + return [] if normalized_categories: placeholders = ", ".join("?" for _ in normalized_categories) rows = conn.execute( @@ -2425,7 +2427,8 @@ class WatchlistStore: def refresh_all(self): refreshed = [] - for show_id in self.all_show_ids(categories=("watching", "planned")): + categories = (self.config_getter() or {}).get("watchlist_refresh_categories", ("watching", "planned")) + for show_id in self.all_show_ids(categories=categories): item = self.refresh(show_id, include_thumbnail=False) if item is not None: refreshed.append(item) @@ -3303,7 +3306,12 @@ def manage_watchlist_category(action, payload): if action == "rename": return store.rename_category(payload.get("category"), payload.get("label")) if action == "delete": - return store.delete_category(payload.get("category")) + result = store.delete_category(payload.get("category")) + current = get_config_snapshot() + selected = current.get("watchlist_refresh_categories") or [] + if payload.get("category") in selected: + save_runtime_config({"watchlist_refresh_categories": [key for key in selected if key != payload["category"]]}) + return result raise ValueError("Unknown watchlist action.") diff --git a/app_support.py b/app_support.py index 9a4053b..7f1d548 100644 --- a/app_support.py +++ b/app_support.py @@ -49,6 +49,7 @@ WATCHLIST_CATEGORY_LABELS = { "dropped": "Dropped", } WATCHLIST_CATEGORY_CHOICES = tuple(WATCHLIST_CATEGORY_LABELS.keys()) +DEFAULT_WATCHLIST_REFRESH_CATEGORIES = ["watching", "planned"] MAX_LOG_LINES = 240 MAX_JSON_BODY_BYTES = 12 * 1024 * 1024 WATCHLIST_REFRESH_REQUEST_TIMEOUT_SECONDS = 8 @@ -309,6 +310,7 @@ DEFAULT_CONFIG = { "provider": "anikoto", "watchlist_auto_refresh_enabled": False, "watchlist_auto_refresh_minutes": WATCHLIST_AUTO_REFRESH_DEFAULT_MINUTES, + "watchlist_refresh_categories": DEFAULT_WATCHLIST_REFRESH_CATEGORIES, "watchlist_backup_enabled": True, "watchlist_backup_minutes": 1440, "watchlist_backup_keep": 14, @@ -413,6 +415,7 @@ def normalize_config(data): download_methods = config.get("download_methods") auto_refresh_enabled = config.get("watchlist_auto_refresh_enabled") auto_refresh_minutes = config.get("watchlist_auto_refresh_minutes") + refresh_categories = config.get("watchlist_refresh_categories") refresh_delay_seconds = config.get("watchlist_refresh_delay_seconds") auto_download_enabled = config.get("auto_download_enabled") auto_download_mode = str(config.get("auto_download_mode", "dub")).lower() @@ -485,6 +488,13 @@ def normalize_config(data): config["provider"] = provider if provider in PROVIDER_CHOICES else "anikoto" config["watchlist_auto_refresh_enabled"] = auto_refresh_enabled config["watchlist_auto_refresh_minutes"] = auto_refresh_minutes + if not isinstance(refresh_categories, list): + refresh_categories = DEFAULT_WATCHLIST_REFRESH_CATEGORIES + config["watchlist_refresh_categories"] = list(dict.fromkeys( + category for value in refresh_categories + if (category := str(value or "").strip().lower()) in WATCHLIST_CATEGORY_CHOICES + or re.fullmatch(r"custom-[0-9a-f]{12}", category) + )) backup_enabled = config.get("watchlist_backup_enabled") config["watchlist_backup_enabled"] = backup_enabled.strip().lower() in {"1", "true", "yes", "on"} if isinstance(backup_enabled, str) else bool(backup_enabled) for key, default, minimum, maximum in (("watchlist_backup_minutes", 1440, 1, 10080), ("watchlist_backup_keep", 14, 1, 365)): diff --git a/config_page.py b/config_page.py index be97ee8..2b3b6a5 100644 --- a/config_page.py +++ b/config_page.py @@ -170,6 +170,15 @@ CONFIG_HTML = r""" max-width: 28ch; } .row > * { flex: 1; } + .watchlist-refresh-option { + display: inline-flex; + align-items: center; + gap: 8px; + width: auto; + min-height: 0; + white-space: nowrap; + } + .watchlist-refresh-option input { width: auto; flex: none; } .page-links { display: grid; gap: 8px; @@ -718,6 +727,7 @@ CONFIG_HTML = r"""

Watchlist management

Create named watchlists. Watching, Planned, Finished and Dropped are fixed. Deleting a custom watchlist moves its entries to Planned.

+
Choose which watchlists are included in scheduled refreshes and Refresh All. Watching and Planned are selected by default. Save settings to apply changes. Refreshing one show directly still works from any watchlist.
Loading watchlists…
@@ -798,6 +808,7 @@ CONFIG_HTML = r""" download_methods: ["kaizoku"], watchlist_auto_refresh_enabled: false, watchlist_auto_refresh_minutes: 60, + watchlist_refresh_categories: ["watching", "planned"], watchlist_backup_enabled: true, watchlist_backup_minutes: 1440, watchlist_backup_keep: 14, @@ -894,6 +905,9 @@ CONFIG_HTML = r""" download_methods: ["kaizoku"], watchlist_auto_refresh_enabled: $("watchlistAutoRefreshEnabled").value === "true", watchlist_auto_refresh_minutes: $("watchlistAutoRefreshMinutes").value, + watchlist_refresh_categories: document.querySelector(".watchlist-refresh-toggle") + ? [...document.querySelectorAll(".watchlist-refresh-toggle:checked")].map((input) => input.value) + : (state.config.watchlist_refresh_categories || ["watching", "planned"]), watchlist_backup_enabled: $("watchlistBackupEnabled").value === "true", watchlist_backup_minutes: $("watchlistBackupMinutes").value, watchlist_backup_keep: $("watchlistBackupKeep").value, @@ -952,6 +966,7 @@ CONFIG_HTML = r""" $("configProvider").value = data.provider || "anikoto"; $("watchlistAutoRefreshEnabled").value = String(Boolean(data.watchlist_auto_refresh_enabled)); $("watchlistAutoRefreshMinutes").value = data.watchlist_auto_refresh_minutes; + state.config.watchlist_refresh_categories = data.watchlist_refresh_categories || ["watching", "planned"]; $("watchlistBackupEnabled").value = String(Boolean(data.watchlist_backup_enabled)); $("watchlistBackupMinutes").value = data.watchlist_backup_minutes; $("watchlistBackupKeep").value = data.watchlist_backup_keep; @@ -1116,6 +1131,15 @@ CONFIG_HTML = r""" const row = document.createElement("div"); row.className = "toolbar"; const label = document.createElement("strong"); label.textContent = entry.label; row.append(label); + const refreshLabel = document.createElement("label"); refreshLabel.className = "watchlist-refresh-option"; + const refresh = document.createElement("input"); refresh.type = "checkbox"; refresh.className = "watchlist-refresh-toggle"; + refresh.value = entry.category; + refresh.checked = (state.config.watchlist_refresh_categories || ["watching", "planned"]).includes(entry.category); + refresh.addEventListener("change", () => { + state.config.watchlist_refresh_categories = [...document.querySelectorAll(".watchlist-refresh-toggle:checked")].map((input) => input.value); + }); + refreshLabel.append(refresh, document.createTextNode("Refresh")); + row.append(refreshLabel); if (!entry.fixed) { const rename = document.createElement("button"); rename.type = "button"; rename.textContent = "Rename"; rename.addEventListener("click", async () => { @@ -1126,7 +1150,7 @@ CONFIG_HTML = r""" const remove = document.createElement("button"); remove.type = "button"; remove.textContent = "Delete"; remove.addEventListener("click", async () => { if (!confirm(`Delete ${entry.label}? Its entries will move to Planned.`)) return; - try { const result = await api("/api/config/watchlist/categories", {method:"POST", body:JSON.stringify({action:"delete", category:entry.category})}); setNotice(result.message); await loadWatchlistCategories(); } catch (error) { setNotice(error.message); } + try { const result = await api("/api/config/watchlist/categories", {method:"POST", body:JSON.stringify({action:"delete", category:entry.category})}); state.config.watchlist_refresh_categories = (state.config.watchlist_refresh_categories || []).filter((key) => key !== entry.category); setNotice(result.message); await loadWatchlistCategories(); } catch (error) { setNotice(error.message); } }); row.append(rename, remove); } diff --git a/http_handler.py b/http_handler.py index 0dc3840..fdda01d 100644 --- a/http_handler.py +++ b/http_handler.py @@ -182,7 +182,7 @@ def normalize_queue_type(value): def queue_list_payload(runtime, page=1, per_page=10, queue_type="all"): page = max(1, int(page or 1)) - per_page = min(50, max(1, int(per_page or 10))) + per_page = min(100, max(1, int(per_page or 10))) queue_type = normalize_queue_type(queue_type) download_queue = runtime["download_queue"] jellyfin_jobs = runtime.get("watchlist_jellyfin_sync") diff --git a/queue_jobs.py b/queue_jobs.py index 90a1b21..c5ae640 100644 --- a/queue_jobs.py +++ b/queue_jobs.py @@ -288,7 +288,8 @@ class WatchlistRefreshJobs: new_episode_items = [] refresh_error_items = [] try: - show_ids = self.store.all_show_ids(categories=("watching", "planned")) + categories = (self.config_getter() or {}).get("watchlist_refresh_categories", ("watching", "planned")) + show_ids = self.store.all_show_ids(categories=categories) delay_seconds = self._refresh_delay_seconds() started_at = now_iso() with self.lock: @@ -1450,7 +1451,7 @@ class DownloadQueue: def list(self, page=1, per_page=10): page = max(1, int(page or 1)) - per_page = min(50, max(1, int(per_page or 10))) + per_page = min(100, max(1, int(per_page or 10))) offset = (page - 1) * per_page with self.lock, self._connect() as conn: total = conn.execute("SELECT COUNT(*) AS count FROM jobs").fetchone()["count"] diff --git a/queue_page.py b/queue_page.py index 5668f4e..1e4da73 100644 --- a/queue_page.py +++ b/queue_page.py @@ -179,6 +179,8 @@ QUEUE_HTML = r""" border-radius: 16px; background: rgba(255, 255, 255, 0.03); } + .queue-pager-controls > * { flex: 0 0 auto; } + .queue-pager-controls select { width: auto; min-width: 78px; } .queue-tab { border: 0; min-height: 38px; @@ -427,6 +429,7 @@ QUEUE_HTML = r"""