hoatv2211/GameStudio-CodexKIT / skills/multi-service-local-environment-doctor
multi-service-local-environment-doctor
VerifiedUse when diagnosing a multi-service local game environment with port conflicts, process listeners, configured ports, service names, startup dependencies, and cross-project isolation concerns.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 3.9 KB |
| agents/openai.yaml | config | 319 B |
| references/commands.md | markdown | 1.5 KB |
| scripts/environment_doctor.py | script | 2.0 KB |
scripts/environment_doctor.py
View on GitHub# Generated by scripts/sync_skill_resources.py. Do not edit manually.
from __future__ import annotations
import argparse
import json
import sys
from collections import defaultdict
from pathlib import Path
from typing import Any
def analyze_services(services: list[dict[str, Any]]) -> dict[str, Any]:
listeners: dict[tuple[str, int], list[str]] = defaultdict(list)
config_mismatches: list[str] = []
normalized: list[dict[str, Any]] = []
for service in services:
required = {"name", "host", "port", "configured_port"}
if set(service) != required:
raise ValueError(f"service requires only {sorted(required)}")
name = str(service["name"])
host = str(service["host"])
port = int(service["port"])
configured_port = int(service["configured_port"])
listeners[(host, port)].append(name)
if port != configured_port:
config_mismatches.append(name)
normalized.append(
{"name": name, "host": host, "port": port, "configured_port": configured_port}
)
conflicts = [
{"host": host, "port": port, "services": sorted(names)}
for (host, port), names in sorted(listeners.items())
if len(names) > 1
]
return {
"status": "PASS" if not conflicts and not config_mismatches else "FAIL",
"services": normalized,
"port_conflicts": conflicts,
"config_mismatches": sorted(config_mismatches),
"limitations": ["Static topology only; active process listeners were not queried."],
}
def main(argv: list[str] | None = None) -> int:
parser = argparse.ArgumentParser(description="Analyze a static multi-service port topology.")
parser.add_argument("config", type=Path)
args = parser.parse_args(argv)
services = json.loads(args.config.read_text(encoding="utf-8"))
report = analyze_services(services)
print(json.dumps(report, indent=2))
return 0 if report["status"] == "PASS" else 1
if __name__ == "__main__":
sys.exit(main())
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |