diff --git a/common/http_client.py b/common/http_client.py index f9c0de2b4..5c633d78d 100644 --- a/common/http_client.py +++ b/common/http_client.py @@ -82,7 +82,8 @@ def _is_sensitive_url(url: str) -> bool: try: if settings.GITHUB_OAUTH is not None: url_val = settings.GITHUB_OAUTH.get("url") - if url_val: oauth_urls.add(url_val) + if url_val: + oauth_urls.add(url_val) except Exception: pass # Feishu OAuth endpoints @@ -90,7 +91,8 @@ def _is_sensitive_url(url: str) -> bool: if settings.FEISHU_OAUTH is not None: for k in ("app_access_token_url", "user_access_token_url"): url_val = settings.FEISHU_OAUTH.get(k) - if url_val: oauth_urls.add(url_val) + if url_val: + oauth_urls.add(url_val) except Exception: pass # Defensive normalization: compare only scheme+netloc+path diff --git a/graphrag/search.py b/graphrag/search.py index c21a0d827..860c58906 100644 --- a/graphrag/search.py +++ b/graphrag/search.py @@ -13,7 +13,6 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import asyncio import json import logging from collections import defaultdict