- Implement 4 production-ready audit scan tools in src/shards/audit.py - scan_status_reconciliation: detect terminated users still enabled in AD - scan_job_title_drift: detect title mismatches between Workday and AD - scan_department_mismatches: detect department/cost center drift - scan_name_variance_mismatches: detect display name inconsistencies - Add comprehensive integration test suite (tests/integration_test_audit_shard.py) - Create demo client (test_client.py) and MCP protocol simulator (test_mcp_protocol.py) - Add tool catalog generator (list_tools.py) for visibility across all 33 registered tools - Fix Windows console encoding in src/main.py to support emoji in shard status output - Add version management utility (scripts/bump_version.py) for release automation - Update workday test imports to use new drift_detection module path Completes session goal of establishing SOC 2-compliant cross-system drift detection per SESSION_SNAPSHOT_2026-04-13.md. All audit tools validated against mock data with expected mismatch scenarios (Bob Martinez, Carol Chen, David Kim cases). Refs: WIS-014, WIS-015, WIS-016, WIS-017, WIS-018
71 lines
1.5 KiB
Python
71 lines
1.5 KiB
Python
#!/usr/bin/env python3
|
|
"""Minimal MCP server for testing VS Code Copilot integration.
|
|
|
|
This is a simplified version to help diagnose MCP server issues.
|
|
If this works, the problem is with the Nexus server configuration.
|
|
If this doesn't work, it's a VS Code/Copilot setup issue.
|
|
"""
|
|
|
|
from mcp.server.fastmcp import FastMCP
|
|
|
|
# Create minimal server
|
|
mcp = FastMCP(
|
|
name="test-server",
|
|
instructions="A minimal MCP server for testing VS Code integration"
|
|
)
|
|
|
|
|
|
@mcp.tool()
|
|
def hello(name: str = "World") -> str:
|
|
"""Say hello to someone.
|
|
|
|
Args:
|
|
name: The name to greet (default: World)
|
|
|
|
Returns:
|
|
A friendly greeting
|
|
"""
|
|
return f"Hello, {name}! MCP server is working! 🎉"
|
|
|
|
|
|
@mcp.tool()
|
|
def test_connection() -> dict:
|
|
"""Test that the MCP connection is working.
|
|
|
|
Returns:
|
|
Status information about the server
|
|
"""
|
|
return {
|
|
"status": "connected",
|
|
"server": "test-server",
|
|
"message": "MCP server is responding correctly",
|
|
"tools_available": 3
|
|
}
|
|
|
|
|
|
@mcp.tool()
|
|
def check_environment() -> dict:
|
|
"""Check environment variables and paths.
|
|
|
|
Returns:
|
|
Environment information
|
|
"""
|
|
import os
|
|
import sys
|
|
|
|
return {
|
|
"python_version": sys.version,
|
|
"python_executable": sys.executable,
|
|
"current_directory": os.getcwd(),
|
|
"use_mock": os.getenv("USE_MOCK", "not set"),
|
|
}
|
|
|
|
|
|
def main():
|
|
"""Run the MCP server."""
|
|
mcp.run(transport="stdio")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|