MCPcopy Create free account
hub / github.com/AutoForgeAI/autoforge / get_project_stats

Function get_project_stats

server/routers/projects.py:101–112  ·  view source on GitHub ↗

Get statistics for a project.

(project_dir: Path)

Source from the content-addressed store, hash-verified

99
100
101def get_project_stats(project_dir: Path) -> ProjectStats:
102 """Get statistics for a project."""
103 _init_imports()
104 assert _count_passing_tests is not None # guaranteed by _init_imports()
105 passing, in_progress, total = _count_passing_tests(project_dir)
106 percentage = (passing / total * 100) if total > 0 else 0.0
107 return ProjectStats(
108 passing=passing,
109 in_progress=in_progress,
110 total=total,
111 percentage=round(percentage, 1)
112 )
113
114
115@router.get("", response_model=list[ProjectSummary])

Callers 4

list_projectsFunction · 0.85
get_projectFunction · 0.85
update_project_settingsFunction · 0.85

Calls 2

_init_importsFunction · 0.85
ProjectStatsClass · 0.50

Tested by

no test coverage detected