Debugging the TEN service
This commit is contained in:
+6
-4
@@ -2,6 +2,7 @@
|
||||
|
||||
import argparse
|
||||
import sys
|
||||
import json
|
||||
from pathlib import Path
|
||||
from services.iview import iViewService
|
||||
from services.ten import TenService
|
||||
@@ -24,7 +25,7 @@ class AutoGrabber:
|
||||
self.config_dir = Path(config_dir)
|
||||
|
||||
self.history_file = self.config_dir / "history"
|
||||
self.series_file = self.config_dir / "series"
|
||||
self.series_file = self.config_dir / "series.json"
|
||||
|
||||
self.dry_run = dry_run
|
||||
self.mark_existing = mark_existing
|
||||
@@ -80,6 +81,7 @@ class AutoGrabber:
|
||||
def process_show(self, config):
|
||||
service_name = config.get("service")
|
||||
source_title = config.get("source_title")
|
||||
source_url = config.get("source_url")
|
||||
|
||||
if not service_name or not source_title:
|
||||
print(f"❌ Skipping invalid entry: {config} (Missing service or source_title)")
|
||||
@@ -103,7 +105,7 @@ class AutoGrabber:
|
||||
print("==============================")
|
||||
|
||||
# 3. Discovery (Ten will handle its own requirement for source_season)
|
||||
seasons = service.discover_seasons(source_title, source_season=source_season)
|
||||
seasons = service.discover_seasons(source_title, source_season=source_season, source_url=source_url)
|
||||
|
||||
if not seasons:
|
||||
# Service will have already printed its specific error message
|
||||
@@ -146,8 +148,8 @@ class AutoGrabber:
|
||||
self.save_history()
|
||||
|
||||
def run(self):
|
||||
for service, source, output in self.series_list:
|
||||
self.process_show(service, source, output)
|
||||
for show_config in self.series_list:
|
||||
self.process_show(show_config)
|
||||
print("\n✅ Done.")
|
||||
|
||||
# -------------------------
|
||||
|
||||
Reference in New Issue
Block a user