feat: catch-up de decisiones previas (Webpage→Url, anti-bot, UI 2-col, tests cross-platform)

Bloque de cambios revisados y validados con el usuario en sesiones
previas que no habian aterrizado en commits propios. Lista por tema:

* enrichers: web_search ahora usa lite.duckduckgo.com como endpoint
  primario (mas tolerante con bot detection desde IP residencial),
  con fallback al endpoint html. Detecta pagina captcha y emite
  error claro si ambos fallan. Anyade _DDGLiteParser para el formato
  lite + auto-pick de parser por contenido.

* enrichers: tipo Webpage unificado en Url (campos de cuerpo
  cacheado viven en metadata del Url). Manifests actualizados
  (applies_to: [Url]). fetch_webpage ya no convierte Url->Webpage.

* enrichers/manifest: campo `params` parseado a EnricherSpec.params
  (name, type, default_value, description). UI puede renderizar
  dialog de configuracion.

* jobs: fix de path conversion para Python embebido nativo Windows
  (no convertir a /mnt/c/... cuando el subproceso es Windows-native;
  solo cuando es bash o python via WSL).

* main.cpp: ventana ImGui (no modal) "Run enricher" con layout
  2-col (label izq, input der). Inserta job con JSON tipado. Layout
  clustering apretado: hijos del mismo anchor en un solo anillo
  alrededor del padre, sin desperdigar por anillos crecientes.

* views: inspector con layout 2-col via BeginTable (Identity,
  Schema fields, Extras). Description full-width debajo de su label.

* tests: portable conftest (auto-detecta REGISTRY_ROOT, PYTHON_BIN,
  ENRICHERS_DIR para WSL y Windows portable). _runner.py trampoline
  inyecta stub via sys.path porque embedded Python ignora PYTHONPATH.
  Tests bash-only (vendor_script, freeze, dispatcher bash, resolver
  Linux-binary) skipean en Windows. Tests existentes adaptados a
  Webpage->Url.

Resultado actual: 32 passed WSL, 21 passed + 11 skipped Windows.
This commit is contained in:
2026-05-03 14:41:28 +02:00
parent 4be5734ce5
commit 7a94160fd2
26 changed files with 973 additions and 241 deletions
+5 -12
View File
@@ -101,25 +101,18 @@ entities:
- { name: country, type: string }
- { name: postcode, type: string }
# Url — unifica el viejo Url (solo metadata) y Webpage (cuerpo
# cacheado). Tras fetch_webpage, los campos `*_path`, `status_code`,
# `fetched_at`, `text_length`, etc. tienen valor; sin haber corrido
# fetch siguen vacios pero el nodo sigue siendo un Url valido.
- name: Url
color: "#89E0FC"
icon: ti-link
principal_field: url
fields:
- { name: url, type: url, required: true }
- { name: title, type: string }
- { name: domain, type: string }
# Documento web descargado. Issue 0027: tipo separado de Url para nodos
# con cuerpo cacheado (HTML+markdown+screenshot). Los enrichers
# fetch_webpage / extract_links / extract_text_entities lo pueblan.
- name: Webpage
color: "#89E0FC"
icon: ti-file-text
principal_field: url
fields:
- { name: url, type: url, required: true }
- { name: title, type: string }
- { name: domain, type: string }
- { name: status_code, type: int }
- { name: content_type, type: string }
- { name: fetched_at, type: date }