fix: address code review feedback - fix type hint and rename test

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-09 02:38:50 +00:00
parent 8c62a6b714
commit 4acad71c8f
2 changed files with 5 additions and 2 deletions
+2 -1
View File
@@ -16,6 +16,7 @@ import json
import logging
import os
from datetime import datetime, timedelta, timezone
from typing import Any
import redis
from celery import shared_task
@@ -1429,7 +1430,7 @@ def _scan_user_watch_folder(
# ---------------------------------------------------------------------------
# Maps source_type values to their per-user scan functions.
_USER_WF_CLOUD_HANDLERS: dict[str, callable] = {} # populated after function defs
_USER_WF_CLOUD_HANDLERS: dict[str, Any] = {} # populated after function defs
def _scan_user_s3_folder(
+3 -1
View File
@@ -3950,7 +3950,9 @@ class TestPullUserIntegrationWatchFolders:
@patch("app.tasks.watch_folder_tasks._scan_user_watch_folder", return_value=4)
@patch("app.tasks.watch_folder_tasks._load_cache", return_value={})
@patch("app.tasks.watch_folder_tasks._save_cache")
def test_local_source_type_uses_local_scanner(self, mock_save, mock_load, mock_scan_local, mock_session_factory):
def test_local_source_type_dispatches_to_local_scanner(
self, mock_save, mock_load, mock_scan_local, mock_session_factory
):
"""Explicit source_type 'local' should use the local filesystem scanner."""
from app.tasks.watch_folder_tasks import _pull_user_integration_watch_folders