a802f59f55
- cmd/fn/doctor.go - cmd/fn/main.go - cpp/apps/primitives_gallery/playground/tables/CMakeLists.txt - cpp/apps/primitives_gallery/playground/tables/data_table.cpp - cpp/apps/primitives_gallery/playground/tables/data_table_logic.cpp - cpp/apps/primitives_gallery/playground/tables/data_table_logic.h - cpp/apps/primitives_gallery/playground/tables/self_test.cpp - cpp/apps/primitives_gallery/playground/tables/tql.cpp - cpp/apps/primitives_gallery/playground/tables/viz.cpp - cpp/apps/primitives_gallery/playground/tables/viz.h - ... Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2.2 KiB
2.2 KiB
name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, params, output, tested, tests, test_file_path, file_path
| name | kind | lang | domain | version | purity | signature | description | tags | uses_functions | uses_types | returns | returns_optional | error_type | imports | params | output | tested | tests | test_file_path | file_path | |||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| vault_manifest_read | function | go | infra | 1.0.0 | impure | func VaultManifestRead(repoRoot string) ([]VaultManifestEntry, error) | Lee todos los manifests vault.yaml bajo projects/*/vaults/ del repo y devuelve una lista plana de entradas de vault con su ProjectID inferido del path. |
|
false | error_go_core |
|
|
Slice plano de VaultManifestEntry (ProjectID, Name, Description, Path, Tags, ManifestFile). Vacio si no hay manifests. Error si un yaml no parsea, con el path concreto en el mensaje. | true |
|
functions/infra/vault_manifest_read_test.go | functions/infra/vault_manifest_read.go |
Ejemplo
entries, err := VaultManifestRead("/home/lucas/fn_registry")
if err != nil {
log.Fatal(err)
}
for _, e := range entries {
fmt.Printf("%s/%s -> %s\n", e.ProjectID, e.Name, e.Path)
}
// app_turismo/turismo_spain -> /home/lucas/vaults/turismo_spain
// app_finance/finance_data -> /home/lucas/vaults/finance_data
Notas
VaultManifestEntry es un tipo local de esta funcion (no un tipo del registry). Contiene:
ProjectID— basename del directorioprojects/<proj>/, inferido del path del manifest.Name,Description,Path,Tags— copiados del yaml tal cual.ManifestFile— path absoluto al vault.yaml de origen, util para mensajes de error y trazabilidad.
El parseo usa gopkg.in/yaml.v3 (ya en go.mod). Si un manifest falla, la funcion devuelve
error inmediatamente con el path del fichero problemático. Los manifests sin entradas
vaults: contribuyen cero entries (no es error). Si no existe ningun projects/*/vaults/vault.yaml
el resultado es slice vacio sin error.