[self-care:pages-health] Bound shard size probe concurrency in dashboard data worker

Abierto Apto para principiantes
#20,028 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
85/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
javascript
Área
frontend

Línea de trabajo

Abre dashboard/site/src/data-worker.js y localiza measureShards; cámbialo para usar un pool de concurrencia de 6 que se detiene en abort en vez de Promise.all. Añade un test unitario en dashboard/site/test/unit/data-worker-shards.test.js que afirme máx 6 solicitudes HEAD in-flight y tamaños registrados. Hecho cuando los tests unitarios existentes data-worker-* pasan y el typecheck pasa.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

agentic-workflows self-care self-care:pages-health

The deployed dashboard is reachable and all 210 Lighthouse runs completed, but navigation coverage is incomplete (136 of 210 page/profile checks) and every recorded browser error is an aborted HEAD request for an activity shard (6,936 in total). This PR bounds the concurrency of those probes; the fix is not performance-validated against production.

Action: Dashboard maintainer: review and merge this PR, then rerun Pages Health and confirm net::ERR_ABORTED shard HEAD requests drop and the incomplete-navigation count falls below 136.

Pages: 70 | Views declared: 142 | Browser errors: 6,936 (0 console/page errors) | Failed requests: 6,936 (all ERR_ABORTED HEAD) | Incomplete checks: 136 navigation, 0 Lighthouse | Profiles: 3 (desktop, mobile, low-bandwidth)

Critical Findings
  • Every error in all three profiles is HEAD https://githubnext.github.io/gh-cao/cao/gh-aw-logs-runs/*.jsonl: net::ERR_ABORTED (desktop 2,285; mobile 4,597; low-bandwidth 54). dashboard/site/src/data-worker.js measureShards issues one unbounded HEAD per pending shard via Promise.all; these requests are aborted when the page swaps or the worker is cancelled.
  • Navigation incomplete: desktop 56/70, mobile 49/70, low-bandwidth 31/70 pages. Blockers are mainly scrollIntoViewIfNeeded: Element is not attached to the DOM (the DOM is re-rendering during scrolling), did not render declared views: view-1, and 30s timeouts waiting for commands, command and governance page roots. A causal link between the HEAD traffic and these blockers is not established.
  • Lighthouse completed for all 70 pages in each profile.
JavaScript Quick Wins
  1. Bound shard HEAD probe concurrency (implemented here). measureShards now uses a pool of 6 workers and stops when the signal aborts, instead of firing one request per shard at once. Not performance-validated; existing data-worker-* unit tests pass (9 files, 17 tests) and typecheck passes.
  2. Reserve layout space for late-rendering view content (not implemented). Mobile CLS is highest on workflow-value (0.744), marketplace-package (0.672), campaign-detail (0.461), campaign-workflows (0.462), tool-runs (0.510); low-bandwidth marketplace-package 0.805 and workflow-value 0.751; desktop audit-runs 0.249. Not performance-validated; needs identification of the shifting elements.
  3. Keep view DOM stable while scrolling (not implemented). The Element is not attached to the DOM blockers indicate views re-render during the scroll pass; avoiding replacement of unchanged view nodes would let the collector complete. Not performance-validated.
Performance by profile and page

Ranges (min / median / max) across 70 pages. Scores are 0–1; times in ms.

Profile Score FCP LCP CLS Speed Index TBT
desktop 0.88 / – / 1 362 / 375 / 474 470 / 483 / 584 0.029 / 0.029 / 0.249 507 / 566 / 842 0 / 0 / 5.5
mobile 0.70 / – / 0.94 1540 / 1544 / 1616 2102 / 2201 / 2402 0 / 0.104 / 0.744 1541 / 1546 / 1905 172 / 241 / 332
low-bandwidth 0.35 / – / 0.62 5040 / 5044 / 5243 7280 / 7310 / 8404 0 / 0.108 / 0.805 5040 / 5044 / 5243 122 / 243 / 327

Lowest scores: desktop audit-runs 0.88; mobile workflow-value and marketplace-package 0.70; low-bandwidth marketplace-package 0.35. Mobile and low-bandwidth runs are slower than desktop on every timing metric; no thresholds are applied. Per-page scores and metrics for all 210 runs are in the perf data of self-care-pages-health-evidence/summary.json (artifact self-care-pages-health-41188813440).

Browser errors and coverage
  • Console errors: 0. Uncaught page errors: 0. HTTP responses ≥400: none recorded.
  • Failed requests: 6,936 HEAD .../gh-aw-logs-runs/*.jsonl net::ERR_ABORTED (desktop 2,285; mobile 4,597; low-bandwidth 54).
  • Incomplete navigation (not treated as passing): desktop 56 pages, mobile 49, low-bandwidth 31, including commands, command, governance, steering, firewall, mcps, repositories, workflow-detail, runs, overview, cost and others; complete pages visited all their declared views. Pages where declared views did not render include view-1 pages (4–5 per profile).
  • Incomplete Lighthouse runs: 0.
  • Full per-page lists are in summary.json.
Audit notes

Collector exit code 0; summary.json and all three profile directories present; 70 declared pages and 142 declared views; 70 Lighthouse results per profile. Methodology: Playwright scrolled each page and view; cold Lighthouse per page and profile. Limitation: only quick win 1 was changed, and no post-change production measurement exists. Artifact: self-care-pages-health-41188813440.

Agent prompt

In dashboard/site/src/data-worker.js, keep measureShards bounded to a small concurrency pool that stops on abort, and add a unit test in dashboard/site/test/unit/data-worker-shards.test.js asserting that no more than 6 shard HEAD requests are in flight at once and that sizes are still recorded.

Control Plane
References

cao: githubnext/gh-cao, correlation: 41188567811-3022


[!NOTE]
This was originally intended as a pull request, but the git push operation failed.

Original error: ERR_SYSTEM: git push failed (exit code 128): remote: Permission to githubnext/gh-cao.git denied to mnkiefer. fatal: unable to access 'https://github.com/githubnext/gh-cao.git/': The requested URL returned error: 403

Workflow Run: View run details and download bundle artifact

The bundle file is available in the agent artifact in the workflow run linked above.

Create the pull request manually
# Download the artifact from the workflow run
gh run download '41188813440' -n agent -D '/tmp/agent-41188813440'

# Resolve the bundle source ref, fetch it into a temporary ref, then create the local branch
bundle_path='/tmp/agent-41188813440/aw-githubnext-gh-cao-self-care-pages-health-shard-probe.bundle'
temp_ref='refs/bundles/create-pr-self-care-pages-health-shard-probe-6db8d454980231a2-bae385e6'
target_ref='refs/heads/self-care/pages-health-shard-probe-6db8d454980231a2'
bundle_source_ref=$(git bundle list-heads "$bundle_path" | awk '$2 ~ /^refs\/heads\// { print $2 }')
if [ -z "$bundle_source_ref" ]; then
  bundle_source_ref=$(git bundle list-heads "$bundle_path" | awk '$2 == "HEAD" { print $2 }')
fi
if [ "$(printf '%s\n' "$bundle_source_ref" | sed '/^$/d' | wc -l | tr -d ' ')" != "1" ]; then
  echo "Expected exactly one bundle source ref, found: $bundle_source_ref" >&2
  exit 1
fi
git fetch "$bundle_path" "${bundle_source_ref}:${temp_ref}"
git update-ref "$target_ref" "$temp_ref"
git checkout 'self-care/pages-health-shard-probe-6db8d454980231a2'
# Ensure the working tree matches the updated branch
git reset --hard
# Remove the temporary bundle ref
git update-ref -d "$temp_ref"

# Push the branch to the target remote
git push 'origin' 'self-care/pages-health-shard-probe-6db8d454980231a2'

# Create the pull request
gh pr create --title '[self-care:pages-health] Bound shard size probe concurrency in dashboard data worker' --base 'main' --head 'self-care/pages-health-shard-probe-6db8d454980231a2' --repo 'githubnext/gh-cao'

Generated by SelfCare / Pages Health · copilot · auto · ~37 AIC · ⌖ ~2 AIC · ⊞ 14.5K · ◷

  • expires on Nov 7, 2026, 10:41 AM UTC
Lenguaje dominante
JavaScript
Estrellas
8
Forks
5
Merge medio
2 h 50 min
PR fusionados (30 d)
814

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de githubnext/gh-cao

Todos los issues de githubnext/gh-cao

Issues similares

Más issues de JavaScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.