Skip to content

Commit 133790f

Browse files
committed
fix(scripts): update outdated imports and references
- run_http_server.py: import run_mcp_server from .run instead of .server - run_tool.py: fix module name list_honey_tokens -> list_honeytokens - test_workspace_setup.py: replace removed GitGuardianFastMCP with get_mcp_server, add actual server module imports in test blocks Issue: APPAI-573
1 parent b2d9f25 commit 133790f

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

scripts/run_http_server.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@
99

1010
if __name__ == "__main__":
1111
# For SecOps server:
12-
from secops_mcp_server.server import run_mcp_server
12+
from secops_mcp_server.run import run_mcp_server
1313

1414
# Or for Developer server:
15-
# from developer_mcp_server.server import run_mcp_server
15+
# from developer_mcp_server.run import run_mcp_server
1616

1717
# Run the server
1818
run_mcp_server()

scripts/run_tool.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from gg_api_core.tools.assign_incident import assign_incident, AssignIncidentParams
22
from gg_api_core.tools.find_current_source_id import find_current_source_id
3-
from gg_api_core.tools.list_honey_tokens import ListHoneytokensParams, list_honeytokens
3+
from gg_api_core.tools.list_honeytokens import ListHoneytokensParams, list_honeytokens
44
from gg_api_core.tools.list_incidents import ListIncidentsParams, list_incidents
55
from gg_api_core.tools.list_repo_occurrences import list_repo_occurrences, ListRepoOccurrencesParams
66
import asyncio

scripts/test_workspace_setup.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -113,24 +113,25 @@ def test_server_classes():
113113
print("\n== Testing server classes ==")
114114

115115
try:
116-
from gg_api_core.mcp_server import GitGuardianFastMCP
116+
from gg_api_core.mcp_server import get_mcp_server
117117

118-
# Just instantiate the class to test it
119118
get_mcp_server("Test Core")
120119
print("✅ Successfully created GitGuardianFastMCP instance")
121120
except Exception as e:
122121
print(f"❌ Failed to create GitGuardianFastMCP instance: {e}")
123122
return False
124123

125124
try:
126-
# Import the server module (with its mcp instance)
125+
import developer_mcp_server.server # noqa: F401
126+
127127
print("✅ Successfully imported developer MCP server module")
128128
except Exception as e:
129129
print(f"❌ Failed to import developer MCP server module: {e}")
130130
return False
131131

132132
try:
133-
# Import the server module (with its mcp instance)
133+
import secops_mcp_server.server # noqa: F401
134+
134135
print("✅ Successfully imported SecOps MCP server module")
135136
except Exception as e:
136137
print(f"❌ Failed to import SecOps MCP server module: {e}")

0 commit comments

Comments
 (0)