Skip to main content
Glama
sudo-ai-git

io.github.sudo-ai-git/mcp-benchmark-hygiene

by sudo-ai-git

mcp-benchmark-hygiene

mcp-name: io.github.sudo-ai-git/mcp-benchmark-hygiene

에이전트 벤치마크 / 함수 채점을 조용히 오염시키는 pytest 설정 누출을 결정적으로 탐지합니다.

LLM 없음. 네트워크 없음. 하나의 질문, 신뢰할 수 있게 답변:

이 워크스페이스 안에서 python -m pytest <tests>를 실행하면, 통과하는 코드를 실패로 오채점하는 호스트 커버리지/중단 게이트를 상속받게 될까요?


이 도구가 잡아내는 버그

자동화된 에이전트 평가 하네스는 종종 대상 워크스페이스 안에서 python -m pytest <hidden_tests>를 실행합니다. 해당 워크스페이스가 pytest addopts를 가진 저장소 루트 아래에 중첩되어 있다면, 예를 들어:

[tool.pytest.ini_options]
addopts = "--cov=harness --cov-report=term-missing:skip-covered --cov-fail-under=80"

...pytest는 그 호스트 pyproject.toml을 rootdir로 해석하고, addopts를 상속받아 호스트 자체의 커버리지 게이트에서 실패합니다(harness가 0%로 수집 → 임계값 미달 → 0이 아닌 종료 코드). 그러면 하네스는 기능적으로 통과하는 코드를 실패로 기록합니다.

이것은 정확히 sudo-ai-git/vulcanbench-findings 에 문서화된 버그입니다: VulcanBench의 선언적 채점기는 이 이유로 모든 기능적 태스크를 0.0으로 오채점했습니다. -o addopts=로 누출을 중화하자, 동일한 워크스페이스가 10/10으로 통과했습니다.

Related MCP server: Debug Companion MCP

이 도구가 건네주는 해결책

워크스페이스가 CORRUPTED로 플래그되면, 도구는 수정된 명령을 반환합니다:

python -m pytest -o addopts= <tests>

-o addopts=는 상속된 커버리지/중단 게이트를 제거합니다. (또는 저장소 루트 밖에서 채점기를 실행하세요.)

도구

도구

용도

inspect_workspace(path)

전체 분석: ini 체인, 유효 addopts, CLEAN/CORRUPTED/UNKNOWN 판정 + 수정된 명령

check_addopts(path)

간단한 불리언: corrupted + 이유

summarize(analysis)

한 줄의 조치 가능한 요약 문자열

결정적 핵심 (의존성 없음)

분석은 워크스페이스 디렉터리에서 파일시스템 루트까지 올라가며, pytest의 첫 발견 순서대로 pyproject.toml / pytest.ini / tox.ini / setup.cfg를 읽고 addopts를 추출합니다. 플래그:

  • 커버리지 게이트--cov, --cov-fail-under, --cov-report, --cov-config

  • 중단/엄격 게이트--maxfail, -x, --strict, --strict-markers, --pdb, --ff

종료 코드를 바꾸거나 채점을 중단시키는 게이트만 플래그됩니다. 무해한 addopts는 정확한 문자열과 함께 CLEAN으로 보고됩니다.

설치 및 실행 (MCP stdio)

한 줄 명령 (권장) — 저장소에서 설치하며 PyPI 토큰이 필요 없습니다:

uv tool install git+https://github.com/sudo-ai-git/mcp-benchmark-hygiene
mcp-benchmark-hygiene                        # run stdio server
mcp-benchmark-hygiene --http --port 8137     # or Streamable HTTP

또는 pipx 사용: pipx install git+https://github.com/sudo-ai-git/mcp-benchmark-hygiene

소스에서 직접 (대체 방법):

{ "mcpServers": {
    "benchmark-hygiene": { "command": "python3", "args": ["/abs/path/to/mcp_server.py"] }
}}

공식 mcp 파이썬 패키지(pip install mcp)가 필요합니다. 결정적 핵심(inspect_workspace / check_addopts / summarize)은 제로 의존성으로 임포트되어 실행됩니다 — mcp 패키지는 stdio 서버에만 필요합니다.

Streamable HTTP (원격/Smithery 게시 가능)

python3 mcp_server.py --http --port 8137   # serves on http://<host>:8137/mcp/

--http로 실행하면 stdio 대신 Streamable HTTP(원격 MCP 엔드포인트)로 서비스합니다. 이것은 URL 기반 게시를 위해 smithery mcp publish <url>이 기대하는 전송 방식입니다 — 따라서 Smithery 서비스 토큰이 있으면 서버는 그대로 배포됩니다.

예시

inspect_workspace(path="/home/runner/vulcanbench/workspace/task-1")
→ {
    "ok": true,
    "workspace": "/home/runner/vulcanbench/workspace/task-1",
    "ini_chain": [{"file": "/home/runner/vulcanbench/pyproject.toml",
                   "addopts": "--cov=harness ... --cov-fail-under=80"}],
    "effective_addopts": "--cov=harness ... --cov-fail-under=80",
    "will_corrupt_grading": true,
    "verdict": "CORRUPTED",
    "fixed_command": ["python3", "-m", "pytest", "-o", "addopts=", "<tests>"],
    "reasons": ["coverage gate(s) present: ['--cov', '--cov-fail-under']"]
}

검증

  • python3 test_detector.py — 5/5 핵심 탐지 검사 (루트 게이트, 중첩 상속, clean, 중단 게이트, pyproject-no-pytest)

  • python3 test_e2e.py — 실제 MCP stdio 전송을 구동하고(initialize → tools/call) CORRUPTED / CLEAN이 와이어를 통해 전달되는지 검증합니다

패밀리의 일부

이것은 sudo-ai-git의 세 가지 결정적, no-LLM 에이전트 신뢰 MCP 서버 중 하나입니다:

라이선스 및 출처

MIT. 문서화된 VulcanBench #79 발견에서 독립적으로 파생되었습니다. morganlinton/VulcanBench의 보증이나 제휴를 암시하지 않습니다.

맞춤 통합 의뢰

이것을 귀하의 내부 시스템(인증, 로깅, 보안 스캔 통과, 호스팅)에 연결해야 합니까? custom-build 요청을 열어 주세요. MIT 참조 자산은 어느 쪽이든 무료로 사용할 수 있습니다.

A
license - permissive license
Not graded
quality - not tested
C
maintenance

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to run and analyze pytest tests for desktop applications through interactive commands. Supports test execution, filtering, result analysis, and debugging for comprehensive test automation workflows.
    2
  • A
    license
    Not graded
    quality
    A
    maintenance
    Local-first MCP and coding-agent reliability harness that captures bounded, sanitized failure evidence and generates deterministic executable regression tests. Capture is opt-in; no API key or hosted service is required.
    2
    Apache 2.0

View all related MCP servers

Related MCP Connectors

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/sudo-ai-git/mcp-benchmark-hygiene'

If you have feedback or need assistance with the MCP directory API, please join our Discord server