Skip to content

~95% on SimpleQA (e.g. Qwen3.6-27B on a 3090). Supports all local and cloud LLMs (llama.cpp, Ollama, Google, ...). 10+ search engines - arXiv, PubMed, your private documents. Everything Local & Encrypted.

refactor: Address AI reviewer minor code quality suggestions

LearningCircuit3d701b8555b0
diff --git a/.github/workflows/responsive-ui-tests-enhanced.yml b/.github/workflows/responsive-ui-tests-enhanced.yml
index d654db7ac8..8ba8761955 100644
--- a/.github/workflows/responsive-ui-tests-enhanced.yml
+++ b/.github/workflows/responsive-ui-tests-enhanced.yml
@@ -198,8 +198,10 @@ jobs:
# Only fail if critical failures
exit "$TEST_EXIT_CODE"
- # NOTE: Screenshot generation and upload steps have been disabled
- # as they are not needed in CI. Enable them if you need visual regression testing.
+ # NOTE: Screenshot generation and upload steps have been removed to fix actionlint warnings.
+ # The actionlint pre-commit hook fails on "if: false" conditions, which were used to disable
+ # these steps. Screenshots are not needed in CI, but can be re-enabled for visual regression
+ # testing by uncommenting the workflow steps below (remove the 'if: false' conditions).
- name: Upload to GitHub Pages (if available)
if: always() && github.event_name == 'pull_request'
diff --git a/src/local_deep_research/web_search_engines/engines/parallel_search_engine.py b/src/local_deep_research/web_search_engines/engines/parallel_search_engine.py
index a5bf8da090..dc88ccb37b 100644
--- a/src/local_deep_research/web_search_engines/engines/parallel_search_engine.py
+++ b/src/local_deep_research/web_search_engines/engines/parallel_search_engine.py
@@ -1,4 +1,5 @@
import json
+import os
import concurrent.futures
from typing import Any, Dict, List, Optional
from threading import Lock
@@ -109,8 +110,6 @@ class ParallelSearchEngine(BaseSearchEngine):
# Persistent thread pool for parallel searches (performance optimization)
# Reusing threads avoids repeated thread creation/destruction overhead
# Use Python's recommended formula for I/O-bound operations if not specified
- import os
-
if max_workers is None:
self.max_workers = min(32, (os.cpu_count() or 1) + 4)
else:
@@ -713,7 +712,7 @@ Select up to {self.max_engines_to_select} engines that would best answer this qu
Args:
wait: If True, wait for all pending tasks to complete before shutdown
"""
- if hasattr(self, "_executor"):
+ if self._executor is not None:
logger.info("Shutting down persistent ThreadPool")
try:
self._executor.shutdown(wait=wait)