Skip to content

Releases: partprogramming09/webscope

0.6.0

Choose a tag to compare

@partprogramming09 partprogramming09 released this 20 Oct 14:25
  • Chrome connector: --tabs lists open tabs, --open <url> focuses or opens one (URL must be under project.base_url), and the tab is found from project.base_url when --url is omitted (exactly one match required). Plan B (AppleScript) always says it acts on your normal Chrome session. The AppleScript tab listing returned title and URL glued together; fixed.
  • webscope --doctor; unknown project keys are reported at start; optional redact patterns for script output; module_graph caches its result; --forms needs route text or --limit <n>; a stale cache file of an older version no longer crashes vue_ts.
  • audit_types narrows columns to the model the request names and marks the rest heuristic (they no longer set exit code 1); requests named Filter, Search, List, Datatable or Export are skipped. Measured precision 89 % on 27 findings (target 90 %).
  • fixtures/laravel and run-engine-checks.sh: read-only refusal, rollback and commit checked on MySQL, PostgreSQL and SQLite.
  • CI on Linux and macOS with Python 3.9 to 3.13; bench/ records environment and token counts and bench/report.py prints the README table from the data.

0.5.1

Choose a tag to compare

@partprogramming09 partprogramming09 released this 20 Oct 07:00

What changed

  • sql now puts the database session in read-only mode (MySQL/MariaDB SET SESSION TRANSACTION READ ONLY, PostgreSQL default_transaction_read_only, SQLite query_only), so the database itself refuses writes. The regex filter on the first keyword stays as a convenience; a WITH ... DELETE now fails with «Cannot execute statement in a READ ONLY transaction».
  • tinker.py accepts a new --read-only flag and only runs PHP files from the system temp folder or the project's storage folder.
  • README grouped by stack, honest token numbers, and a new docs/project.md with every project key (default, who uses it, example).

Breaking

tinker.py rejects PHP files outside the system temp folder and the project storage folder. If you passed your own scripts from elsewhere, copy them into the storage folder (.agents/webscope/, .claude/webscope/ or .webscope/).

0.5.0

Choose a tag to compare

@partprogramming09 partprogramming09 released this 20 Oct 06:39

What's new

Eleven generic adapters, so a project only needs its webscope.json:

tinker, sql, fields, consumers, graph, audit_types, unique_indexes, tenant_queries, simulate, snap, triage, changed. webscope --init adds them for Laravel projects. The README lists each one and the new project keys.

Database adapters run in a transaction that is rolled back; only tinker --commit and cleanup_test_rows --delete --confirm (behind run_write) commit.

Breaking changes from 0.4.0

Before Now
project.tinker (path of your own script) project.container (Docker) or project.workdir (local artisan), plus project.boot for tenant or connection setup
project.sql (your own SQL script) not needed; sql runs through tinker. If you keep one, project.query still uses it

How to upgrade

  1. pip install -U webscope-mcp.
  2. Replace project.tinker with container or workdir. If your script prepared a tenant, move that PHP into project.boot.
  3. Run webscope --init <folder> --force in a copy to see the new script entries and copy the ones you want.

0.4.0

Choose a tag to compare

@partprogramming09 partprogramming09 released this 20 Oct 06:06

What changed

Everything public in Webscope is now in English. This is a breaking change: old names stop working, there are no aliases.

Before Now
tools buscar, leer, correr, correr_escritura search, read, run, run_write
parameters texto, donde, tope, formato, archivo, lineas... text, where, limit, format, file, lines...
manifest keys recorte, raices_extra, prefijo_rutas, contenedor... trim, extra_roots, path_prefix, container...
env var WEBSCOPE_ESCRITURA WEBSCOPE_WRITE
package folder webscope_adaptadores webscope_adapters (token {adaptadores} is now {adapters})
adapter scripts and flags (mapa, --captura, --recorrido...) map, --capture, --walkthrough...

Messages, docstrings, the README and the example agent are in English too.

How to upgrade from 0.3.0

  1. pip install -U webscope-mcp (or uvx picks it up on the next start).
  2. Regenerate the manifest: webscope --init <project folder>, or rename the keys by hand using the table above.
  3. In your agents and .mcp.json, replace the old tool names (mcp__webscope__buscar -> mcp__webscope__search, etc.) and WEBSCOPE_ESCRITURA -> WEBSCOPE_WRITE.
  4. Move stored walkthroughs/flows/map to the new names (walkthroughs/, flows/, module-map.json).

v0.3.0

Choose a tag to compare

@partprogramming09 partprogramming09 released this 20 Oct 04:11

e2e_chrome --ejecutar por CDP (plan B osascript), adaptadores de formulario por librería, instrucciones armadas desde el manifiesto, versión única, controles de seguridad y CI.

v0.2.4 - Aislamiento dinámico y exportador de agentes

Choose a tag to compare

@partprogramming09 partprogramming09 released this 19 Oct 21:43

Novedades en v0.2.4

📁 Resolución Dinámica de Almacenamiento y Cero Invasión

  • Desacoplamiento de rutas fijas: Webscope detecta automáticamente dónde guardar su persistencia interna (mapa-modulos.json, flujos/, recorridos/):
    • Si el proyecto usa .agents/, guarda en .agents/webscope/.
    • Si el proyecto usa .claude/, guarda en .claude/webscope/.
    • Si no existe ninguna (p. ej. en Cursor o VS Code), guarda en .webscope/ limpio en la raíz.
  • Configuración explícita en webscope.json mediante "almacenamiento".

🏷️ Prefijo de Prueba Configurable (prefijo_prueba)

  • Se añade soporte para "prefijo_prueba" en webscope.json (por defecto ZZ_E2E).
  • Permite adaptar las pruebas a proyectos y bases de datos que usen prefijos corporativos propios (p. ej. DEV_TEST_, MOCK_, QA_).

🤖 Exportador No Destructivo de Agente (webscope-mcp --agente)

  • Comando webscope-mcp --agente [directorio] (o python3 webscope.py --agente [directorio]):
    • Exporta la plantilla de subagente recorrido.md en .agents/ o .claude/agents/ con las herramientas ligeras declaradas (tools: Read, Grep, Glob, mcp__webscope__*).
    • Protección estricta: jamás sobreescribe recorrido.md si ya existe (requiere --force) y respeta al 100% todos los demás agentes existentes del usuario (explorer.md, debugger.md, etc.).

🧪 Suite de Pruebas

  • 112/112 tests unitarios pasando al 100% en 4.44s (python3 -I test_webscope.py).
  • Incluye nuevos tests de regresión: test_resolucion_almacenamiento_y_prefijo y test_exportar_agente_no_destructivo.

v0.2.3 - Reutilización nativa de Chrome abierto

Choose a tag to compare

@partprogramming09 partprogramming09 released this 19 Oct 20:54

Novedades en v0.2.3

🚀 Conector Nativo a Chrome Abierto (--evaluar)

  • Permite interactuar directamente con la pestaña activa de Google Chrome del usuario (o buscando por coincidencia de URL) reutilizando su sesión existente, perfiles, cookies y logins sin abrir navegadores limpios en incógnito:
    # Inspeccionar la pantalla en la pestaña activa
    python3 webscope_adaptadores/e2e_chrome.py --evaluar "window.__f.estado()"
    
    # O buscando una pestaña por coincidencia de URL
    python3 webscope_adaptadores/e2e_chrome.py --evaluar "window.__f.estado()" "localhost:5173"
    
    # O ejecutando un archivo de prueba completo
    python3 webscope_adaptadores/e2e_chrome.py --evaluar mi_flujo.js "localhost:5173"

⚡ Autodetección e Inicialización Rápida (webscope-mcp --init)

  • Comando webscope-mcp --init (o python3 webscope.py --init) para autogenerar webscope.json en 1 segundo detectando el framework del proyecto:
    • Laravel: configura app, routes, resources y adaptadores db_check y laravel.
    • Vue / React / Frontend SPA: indexa src, extensiones vue, ts, js y scripts vue_ts y e2e_chrome.
    • Astro / Python / Genérico: adaptado al stack detectado.

🛡️ Tolerancia a Recargas de Página (Self-Healing en Chrome)

  • Eliminado el error abortivo "sin captura: pega primero e2e_chrome --captura".
  • Los ayudantes de formulario (window.__f) y la captura de red (window.__e2e) ahora se auto-inicializan y auto-reinyectan bajo demanda si la página se recargó.

🔌 Gestión Inteligente de Puertos

  • Detección y reutilización automática del receptor HTTP local en http://127.0.0.1:5198/, evitando errores de socket OSError: Address already in use.
  • Soporte para ejecución 100% nativa sin servidor HTTP ni puertos locales mediante --solo-js.

🧪 Suite de Pruebas

  • 110/110 tests unitarios pasando al 100% en 4.08s (python3 -I test_webscope.py).
  • Nuevos tests de regresión incluidos: test_ejecutar_en_chrome, test_init_autodeteccion, test_reinyectar_si_falta, y test_puerto_reutilizacion.

v0.2.2 - Autodetección init, puertos inteligentes y reinyección

Choose a tag to compare

@partprogramming09 partprogramming09 released this 19 Oct 20:26

Webscope v0.2.2 — Autodetección de Proyectos, Tolerancia a Recargas y Puertos Inteligentes

Esta versión introduce mejoras clave en versatilidad multi-proyecto, robustez ante recargas de página en el navegador y simplificación total del canal de comunicación con Claude in Chrome.


🚀 Novedades Principales

1. Autodetección e Inicialización Rápida (webscope-mcp --init)

  • Configuración en 1 segundo: Ejecuta webscope-mcp --init (o python3 webscope.py --init) en la raíz de cualquier proyecto para autogenerar su webscope.json óptimo.
  • Detección inteligente de stacks:
    • Laravel: Detecta composer.json y configura directorios app, routes, resources, database, extensiones php, vue, js y adaptadores empaquetados (db_check, laravel).
    • Vue / React / Frontend SPA: Detecta package.json, indexa src, extensiones vue, ts, tsx, js y habilita scripts vue_ts y e2e_chrome.
    • Astro: Configura rutas, componentes .astro y mapeo de endpoints.
    • Python / Backend: Configura src, app y extensiones py, sql, json.
    • Genérico: Crea configuración limpia y segura para cualquier otro lenguaje o proyecto.
  • No sobreescribe configuraciones existentes a menos que se use la bandera --force.

2. Tolerancia a Recargas de Página (Self-Healing en Chrome)

  • Eliminación del bloqueo sin captura: Si una navegación completa o recarga del navegador (window.location.reload()) limpiaba la memoria de la pestaña, los comandos anteriores abortaban pidiendo volver a inyectar la captura.
  • Auto-inicialización en caliente: Los ayudantes de formulario (window.__f) y la captura de red (window.__e2e) ahora se auto-inicializan y auto-reinyectan bajo demanda, garantizando que los scripts de prueba continúen su ejecución sin interrupciones ni pérdida de contexto.

3. Gestión Inteligente de Puertos y Canal Nativo Chrome

  • Reutilización transparente de socket: Si el receptor local en http://127.0.0.1:5198 ya está activo, el sistema lo detecta mediante sondeo HTTP y lo reutiliza automáticamente en lugar de lanzar OSError: [Errno 48] Address already in use.
  • Ejecución 100% nativa sin puertos: Con la bandera --solo-js, el JavaScript generado se evalúa directamente dentro de la herramienta javascript_tool de Claude in Chrome o DevTools, devolviendo los resultados por el propio canal del navegador sin necesidad de abrir servidores HTTP locales ni puertos adicionales.

🧪 Calidad, Rigor y Verificación

  • 109 tests unitarios pasando al 100% en 3.99 segundos (python3 -I test_webscope.py).
  • Comprobación estricta de fallo previo: Cada cambio se validó asegurando que un test fallara antes del fix y pasara después:
    • test_puerto_reutilizacion: validó la detección y reutilización segura del puerto 5198.
    • test_reinyectar_si_falta: validó la auto-inicialización ante ausencia de variables de memoria.
    • test_init_autodeteccion: validó la creación de manifiestos multi-stack.
  • Verificación en entorno aislado: Paquete .whl probado en un entorno virtual temporal (/tmp/test_venv), confirmando inicialización JSON-RPC y ejecución correcta del binario webscope-mcp.

📦 Instalación y Actualización

Claude Code (con uvx, sin clonar)

# Para el proyecto actual
claude mcp add --scope project webscope -- uvx --from git+https://github.com/partprogramming09/webscope@v0.2.2 webscope-mcp --manifest "$PWD/webscope.json"

# Si ya tenías una versión previa, actualiza la caché
uv cache clean webscope-mcp

Claude Desktop, Cursor, VS Code y Cline

Actualiza los argumentos de tu configuración MCP (claude_desktop_config.json o .cursor/mcp.json):

{
  "mcpServers": {
    "webscope": {
      "command": "uvx",
      "args": [
        "--from",
        "git+https://github.com/partprogramming09/webscope@v0.2.2",
        "webscope-mcp",
        "--manifest",
        "/ruta/a/tu/proyecto/webscope.json"
      ]
    }
  }
}

Con Pip

pip install --upgrade --force-reinstall git+https://github.com/partprogramming09/webscope.git@v0.2.2

v0.2.1: Estandarización de packaging MCP y assets completos

Choose a tag to compare

@partprogramming09 partprogramming09 released this 19 Oct 19:31

Novedades en v0.2.1

  • Packaging PyPA estandarizado (PEP 621 / 639):
    • Declaración explícita de subpaquetes y package-data para inclusión de assets internos.
    • Inclusión de para verificación de integridad de BD.
    • Inclusión de plantillas de agente en .
    • Inclusión de scripts JS del navegador en .
  • Resolución jerárquica de recursos:
    • Soporte de ejecución tanto en entorno local clonado como instalado vía wheel / pip / uvx.
  • Suite de pruebas:
    • Incorporación de test_packaging_integrity verificando el 100% de assets empaquetados.
    • 106 tests unitarios pasando en verde.