chore(plan): marca Phase C (Tasks 10-12) completada
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -1393,7 +1393,7 @@ git commit -m "feat(llm): añade factory que selecciona proveedor según setting
|
|||||||
- Create: `tests/fixtures/policies/test_policy/index.yaml`
|
- Create: `tests/fixtures/policies/test_policy/index.yaml`
|
||||||
- Create: `tests/fixtures/policies/test_policy/versions/v1.yaml`
|
- Create: `tests/fixtures/policies/test_policy/versions/v1.yaml`
|
||||||
|
|
||||||
- [ ] **Step 1: Crear fixtures**
|
- [x] **Step 1: Crear fixtures**
|
||||||
|
|
||||||
`tests/fixtures/policies/test_policy/index.yaml`:
|
`tests/fixtures/policies/test_policy/index.yaml`:
|
||||||
```yaml
|
```yaml
|
||||||
@@ -1424,7 +1424,7 @@ output_validators:
|
|||||||
on_validator_error: fail_closed
|
on_validator_error: fail_closed
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 2: Test**
|
- [x] **Step 2: Test**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""Tests del PolicyStore."""
|
"""Tests del PolicyStore."""
|
||||||
@@ -1464,7 +1464,7 @@ def test_list_versions() -> None:
|
|||||||
assert metas[0].author == "pytest"
|
assert metas[0].author == "pytest"
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 3: Implementar**
|
- [x] **Step 3: Implementar**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""PolicyStore basado en sistema de ficheros (YAML por versión + index.yaml)."""
|
"""PolicyStore basado en sistema de ficheros (YAML por versión + index.yaml)."""
|
||||||
@@ -1528,7 +1528,7 @@ class FileSystemPolicyStore:
|
|||||||
return value if isinstance(value, datetime) else datetime.fromisoformat(value.replace("Z", "+00:00"))
|
return value if isinstance(value, datetime) else datetime.fromisoformat(value.replace("Z", "+00:00"))
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 4: Verificar y commit**
|
- [x] **Step 4: Verificar y commit**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
pytest tests/unit/test_policy_store.py -v
|
pytest tests/unit/test_policy_store.py -v
|
||||||
@@ -1547,7 +1547,7 @@ git commit -m "feat(registry): añade FileSystemPolicyStore con carga YAML versi
|
|||||||
- Create: `tests/fixtures/agents/test_agent/index.yaml`
|
- Create: `tests/fixtures/agents/test_agent/index.yaml`
|
||||||
- Create: `tests/fixtures/agents/test_agent/versions/v1.yaml`
|
- Create: `tests/fixtures/agents/test_agent/versions/v1.yaml`
|
||||||
|
|
||||||
- [ ] **Step 1: Crear fixtures**
|
- [x] **Step 1: Crear fixtures**
|
||||||
|
|
||||||
`tests/fixtures/agents/test_agent/index.yaml`:
|
`tests/fixtures/agents/test_agent/index.yaml`:
|
||||||
```yaml
|
```yaml
|
||||||
@@ -1583,7 +1583,7 @@ risk_threshold_for_hitl: 4
|
|||||||
updated_at: 2026-01-01T00:00:00Z
|
updated_at: 2026-01-01T00:00:00Z
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 2: Test**
|
- [x] **Step 2: Test**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""Tests del AgentRegistry."""
|
"""Tests del AgentRegistry."""
|
||||||
@@ -1660,7 +1660,7 @@ def test_diff_versions_retorna_unified_diff(tmp_path: Path) -> None:
|
|||||||
assert diff.to_version == "v2"
|
assert diff.to_version == "v2"
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 3: Implementar `versioning.py`**
|
- [x] **Step 3: Implementar `versioning.py`**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""Helpers de versionado: hash de contenido, diff unified entre versiones."""
|
"""Helpers de versionado: hash de contenido, diff unified entre versiones."""
|
||||||
@@ -1696,7 +1696,7 @@ def unified_diff(text_a: str, text_b: str, label_a: str, label_b: str) -> str:
|
|||||||
)
|
)
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 4: Implementar `repository.py`**
|
- [x] **Step 4: Implementar `repository.py`**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""AgentRegistry basado en sistema de ficheros (YAML versionado, simulación tipo Git)."""
|
"""AgentRegistry basado en sistema de ficheros (YAML versionado, simulación tipo Git)."""
|
||||||
@@ -1822,7 +1822,7 @@ class FileSystemAgentRegistry:
|
|||||||
return value if isinstance(value, datetime) else datetime.fromisoformat(str(value).replace("Z", "+00:00"))
|
return value if isinstance(value, datetime) else datetime.fromisoformat(str(value).replace("Z", "+00:00"))
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 5: Verificar y commit**
|
- [x] **Step 5: Verificar y commit**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
pytest tests/unit/test_registry.py -v
|
pytest tests/unit/test_registry.py -v
|
||||||
@@ -1837,7 +1837,7 @@ git commit -m "feat(registry): añade FileSystemAgentRegistry con versionado tip
|
|||||||
**Files:**
|
**Files:**
|
||||||
- Create: `core/src/agentforge_core/registry/factory.py`
|
- Create: `core/src/agentforge_core/registry/factory.py`
|
||||||
|
|
||||||
- [ ] **Step 1: Implementar**
|
- [x] **Step 1: Implementar**
|
||||||
|
|
||||||
```python
|
```python
|
||||||
"""Factories para AgentRegistry y PolicyStore basados en Settings."""
|
"""Factories para AgentRegistry y PolicyStore basados en Settings."""
|
||||||
@@ -1856,7 +1856,7 @@ def build_policy_store(settings: Settings) -> FileSystemPolicyStore:
|
|||||||
return FileSystemPolicyStore(settings.policies_dir)
|
return FileSystemPolicyStore(settings.policies_dir)
|
||||||
```
|
```
|
||||||
|
|
||||||
- [ ] **Step 2: Commit**
|
- [x] **Step 2: Commit**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git add core/src/agentforge_core/registry/factory.py
|
git add core/src/agentforge_core/registry/factory.py
|
||||||
|
|||||||
Reference in New Issue
Block a user