[self-care:server-go-logging] Extract ADX visibility digest comparison with diagnostic logging

Abierto Apto para principiantes
#21,725 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
62/100
Tipo de issue
Refactorización
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
go

Línea de trabajo

Comienza con server/internal/adxingest/client.go, especialmente con Client.Verify y la función propuesta checkVisibleDigests. Revisa las pruebas unitarias directas para cada modo de fallo de visibilidad indicado y, a continuación, ejecuta go -C server test ./.... El cambio estará terminado cuando Verify siga siendo equivalente en comportamiento, los registros de diagnóstico expongan únicamente códigos de motivo fijos y recuentos, y toda la suite de pruebas pase.

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

Descripción

agentic-workflows self-care self-care:server-go-logging

Extracts the ADX projection visibility comparison from Client.Verify into checkVisibleDigests in server/internal/adxingest/client.go. Behavior is unchanged, and the comparison now has debug logging and direct unit tests.

Action: Reviewer should confirm Verify is behavior-identical and that the new tests cover each visibility-failure mode; acceptance is a green go -C server test ./....

Summary
  • Subsystem: server/internal/adxingest (next after internal/admission/service.go in the stable path rotation; earlier files had recently been refactored).
  • Refactor boundary: the post-query step of Verify (decode Table/RowDigest rows, sort, compare against expected table:digest entries) is now a pure function. The one intentional internal difference is that sorting no longer reorders the caller's expected slice; it was local to Verify, so there is no observable change.
  • Diagnostics: three cao:adx:client debug logs, reusing the existing package logger, one per failure reason (unexpected_shape, non_string_cell, digest_mismatch). Each logs only fixed reason codes and integer counts. Nothing logged is secret, user-authored, or a raw row, digest, table name, or URL. Logging is off by default and has no effect on control flow.
Tests added

TestCheckVisibleDigests runs real values through the production function. Cases:

  • exact match, order independence, unsorted expected
  • nothing expected or visible
  • missing, unexpected, wrong-digest and wrong-table rows
  • short and extra-column rows
  • non-string table and digest cells

TestCheckVisibleDigestsDoesNotReorderExpected verifies the caller's slice is untouched. No mocks, fakes, or stubs.

Validation
  • gofmt -l server/internal/adxingest: clean
  • go -C server vet ./...: clean
  • go -C server test ./...: all packages pass
  • Diff scanned for secrets: none
Control Plane

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

Original error: ERR_VALIDATION: pushSignedCommits: refusing unsigned push for branch 'self-care/server-go-logging-adx-visibility-14b1bd465a4945b9': GitHub did not verify the initial commit signature; refusing to publish branch 'self-care/server-go-logging-adx-visibility-14b1bd465a4945b9'

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 '46140098759' -n agent -D '/tmp/agent-46140098759'

# Resolve the bundle source ref, fetch it into a temporary ref, then create the local branch
bundle_path='/tmp/agent-46140098759/aw-githubnext-gh-cao-self-care-server-go-logging-adx-visibility.bundle'
temp_ref='refs/bundles/create-pr-self-care-server-go-logging-adx-visibility-14b1bd465a4945b9-0d9f8b97'
target_ref='refs/heads/self-care/server-go-logging-adx-visibility-14b1bd465a4945b9'
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/server-go-logging-adx-visibility-14b1bd465a4945b9'
# 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/server-go-logging-adx-visibility-14b1bd465a4945b9'

# Create the pull request
gh pr create --title '[self-care:server-go-logging] Extract ADX visibility digest comparison with diagnostic logging' --base 'main' --head 'self-care/server-go-logging-adx-visibility-14b1bd465a4945b9' --repo 'githubnext/gh-cao'

Generated by SelfCare / Server Go Logging · copilot · routed: sonnet55 high · ~72 AIC · ⌖ ~2 AIC · ⊞ 9.1K · history

  • expires on Dec 5, 2026, 11:40 AM UTC
Lenguaje dominante
JavaScript
Estrellas
23
Forks
8
Merge medio
7 h 18 min
PR fusionados (30 d)
426

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.