Skip to content

v1.4.1 — Fix del puente de navegador (Líder/Tottus ahora sí resuelven)

Choose a tag to compare

@NLACE-COM NLACE-COM released this 09 Jul 20:34
7541a51

Corrige la 1.4.0: el puente automático nunca resolvía Líder/Tottus por tres bugs que solo se ven contra el sitio real (los tests con fixtures no los detectaban).

🐛 Fixed

  • __NEXT_DATA__ + nonce de CSP — el navegador real inyecta <script nonce="" id="__NEXT_DATA__" …> (nonce antes del id); el marcador literal no lo matcheaba y Líder se reportaba blocked con los datos presentes. Nuevo nextData.ts (extractNextDataJson/hasNextData, tolerante al orden de atributos), compartido por Líder y Tottus.
  • fetchSsrHtml / navegaciónnetworkidle nunca se cumple (analytics/polling) → timeout. Ahora domcontentloaded.
  • fetchSsrHtml / selectorwaitForSelector esperaba visible, pero un <script> es invisible → timeout. Ahora state: "attached".

✅ Verificación

Contra los sitios reales (Chrome real, channel: "chrome"): Líder ~46 productos, Tottus ~48. 157 tests.

Changelog: CHANGELOG.md

🤖 Generated with Claude Code