Skip to content

Commit b13e365

Browse files
Merge branch 'codeql-python' of https://github.com/GitHubSecurityLab/seclab-taskflows into codeql-python
2 parents a864ffa + ab3ec17 commit b13e365

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

src/seclab_taskflows/mcp_servers/codeql_python/mcp_server.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,17 @@
1313

1414
from pydantic import Field
1515
#from mcp.server.fastmcp import FastMCP, Context
16-
from fastmcp import FastMCP, Context # use FastMCP 2.0
16+
from fastmcp import FastMCP # use FastMCP 2.0
1717
from pathlib import Path
1818
import os
1919
import csv
2020
import json
2121
from sqlalchemy import create_engine
2222
from sqlalchemy.orm import Session
2323

24-
import zipfile
25-
import httpx
26-
import aiofiles
24+
25+
26+
2727
from .codeql_sqlite_models import Base, Source
2828

2929
MEMORY = Path(os.getenv('CODEQL_SQLITE_DIR', default='/app/my_data'))
@@ -165,6 +165,8 @@ def remote_sources(owner: str, repo: str,
165165
results = _run_query('remote_sources', database_path, language, {})
166166

167167
# Check if results is an error (list of strings) or valid data (list of dicts)
168+
if isinstance(results, str):
169+
return f"Error: {results}"
168170
if results and isinstance(results[0], str):
169171
return f"Error: {results[0]}"
170172

src/seclab_taskflows/taskflows/audit/remote_sources_local.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ taskflow:
6060
If it is a web endpoint, identify the routing path that reaches this source, HTTP method,
6161
any middlewares used, which roles are allowed to call it.
6262
Note which kind of authentication is required for that endpoint.
63-
It is possible that the source does not have require any authentication.
63+
It is possible that the source does not require any authentication.
6464
If authorization is required, note the details.
6565
6666
Update the source entry in the codeql_sqlite database with your findings.

0 commit comments

Comments
 (0)