call back logs

This commit is contained in:
2025-11-01 19:03:30 +01:00
parent 9fce617949
commit 57c30a0156
4 changed files with 942 additions and 14 deletions

View File

@@ -326,7 +326,14 @@ class SeriesApp:
# (dict with detailed progress info)
if callback:
logger.debug(f"Calling progress callback: {web_progress_dict}")
callback(web_progress_dict)
try:
callback(web_progress_dict)
logger.debug("Progress callback executed successfully")
except Exception as e:
logger.error(
f"Error in progress callback: {e}",
exc_info=True
)
# Propagate progress into the legacy callback chain so
# existing UI surfaces continue to receive updates without

View File

@@ -698,6 +698,10 @@ class DownloadService:
Returns:
Callback function for progress updates
"""
logger.info(
f"Creating progress callback for item {item.id}"
)
def progress_callback(progress_data: dict) -> None:
"""Update progress and broadcast to clients."""
try:
@@ -824,6 +828,10 @@ class DownloadService:
# Create progress callback
progress_callback = self._create_progress_callback(item)
logger.info(
f"Passing callback {progress_callback} to anime_service for "
f"item {item.id}"
)
# Execute download via anime service
# Use serie_folder if available, otherwise fall back to serie_id