chore: snapshot WIP previo + flow 0008 + 7 sub-issues (0112-0119)

Snapshot de WIP acumulado de sesiones previas antes de merge wave 1
del flow 0008 (kanban_cpp + agent_runner_api + DoD schema).

Incluye:
- dev/flows/0008-kanban-cpp-and-agent-workflows.md
- dev/issues/0112-0119*.md (7 sub-issues)
- WIP previo en cmd/fn/doctor.go, registry/*, modules/, cpp/, etc.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-18 18:17:08 +02:00
parent ddb5366884
commit b9716a7cd6
119 changed files with 14929 additions and 3084 deletions
+55
View File
@@ -39,6 +39,8 @@ func cmdDoctor(args []string) {
doctorArtefacts(r, jsonOut)
case "services":
doctorServices(r, jsonOut)
case "services-spec":
doctorServicesSpec(r, jsonOut)
case "sync":
doctorSync(r, jsonOut)
case "uses-functions":
@@ -80,6 +82,7 @@ Subcommands:
(none)|all Corre todos los checks
artefacts Salud de apps y analyses (git, venv, app.md, upstream)
services Estado de apps con tag 'service' (systemd + puerto)
services-spec Audit del bloque service: en app.md de apps tag 'service' (issue 0105)
sync Drift entre pc_locations BD y disco
uses-functions Audit imports reales vs uses_functions del app.md
unused Funciones del registry sin consumidores
@@ -291,6 +294,58 @@ func doctorServices(root string, jsonOut bool) {
w.Flush()
}
func doctorServicesSpec(root string, jsonOut bool) {
audits, err := infra.AuditServicesSpec(root)
if err != nil {
fmt.Fprintf(os.Stderr, "error: %v\n", err)
os.Exit(1)
}
if jsonOut {
emit(audits)
return
}
if len(audits) == 0 {
fmt.Println("No services declared (no apps with tag 'service').")
return
}
bad := 0
w := tabwriter.NewWriter(os.Stdout, 0, 0, 2, ' ', 0)
fmt.Fprintln(w, "STATUS\tAPP\tRUNTIME\tPORT\tHEALTH\tUNIT\tTARGETS\tISSUES")
for _, a := range audits {
status := "OK"
issues := "-"
if !a.OK {
status = "FAIL"
issues = strings.Join(a.Issues, "; ")
bad++
}
port := "-"
if a.Port > 0 {
port = fmt.Sprintf("%d", a.Port)
}
health := a.HealthPath
if health == "" {
health = "-"
}
unit := a.SystemdUnit
if unit == "" {
unit = "-"
}
targets := strings.Join(a.PCTargets, ",")
if targets == "" {
targets = "-"
}
runtime := a.Runtime
if runtime == "" {
runtime = "-"
}
fmt.Fprintf(w, "%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\n",
status, a.Name, runtime, port, health, unit, targets, issues)
}
w.Flush()
fmt.Printf("\n%d/%d services with complete service: block.\n", len(audits)-bad, len(audits))
}
func doctorSync(root string, jsonOut bool) {
drifts, err := infra.PcLocationsDrift(root, "")
if err != nil {