fix: stop the access log watcher when Charon shuts down
Los mantenedores suelen responder en 1 día
@Wikid82 ya está trabajando en esto.
Desde el 3/12/2026.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 76/100
Línea de trabajo
Read backend/internal/services/log_watcher.go and the watcher setup in backend/internal/api/routes/routes.go; compare how the stats ingester and hub receive the application context. Start by tracing LogWatcher.Start(ctx) and its tail loop. Add a test that cancellation stops the loop, then verify the watcher shuts down with server.Run(ctx) and releases its resources.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What
The access log watcher keeps running until the process exits instead of stopping with the application context.
backend/internal/api/routes/routes.go(log watcher block,logWatcher.Start(context.Background())) starts it with a background context, and nothing callsLogWatcher.Stop()at shutdown.LogWatcher.Start(ctx)(backend/internal/services/log_watcher.go:45) ignores itsctxargument; the tail loop watches the watcher's own context created inNewLogWatcher(:34-42).
CLAUDE.md asks long-running work to respect server.Run(ctx).
Severity
Low. The process exits at shutdown anyway; the gap is an unclean stop (open file handle, subscriber channels left open) and a pattern that differs from the stats ingester and hub, which take ctx.
Suggested approach
Have Start derive the tail loop's context from its ctx argument (or call Stop from context.AfterFunc(ctx, ...)), pass the application context from RegisterWithDeps, and add a test that the tail loop ends when the context is cancelled.
Found while planning #2132.
- Lenguaje dominante
- Go
- Estrellas
- 17
- Forks
- 2
- Merge medio
- 1 h 42 min
- PR fusionados (30 d)
- 173
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de Wikid82/Charon
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
Docs promise signed SLSA provenance that the image build does not producePosiblemente ocupada @Wikid82 la tomó hoy. Abiertoarchitecture documentation security ui
Wikid82/Charon#2152 · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Orthrus agent images are not signed or SBOM-attestedPosiblemente ocupada @Wikid82 la tomó hoy. Abiertosecurity ssl testing
Wikid82/Charon#2151 · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Registry prune deletes release image signatures and SBOM attestations on GHCR after 7 daysPosiblemente ocupada @Wikid82 la tomó hoy. Abiertocritical testing
Wikid82/Charon#2150 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Minor follow-ups from the country-allow-list local-network reviewPosiblemente ocupada @Wikid82 la tomó hoy. Abiertoarchitecture backend documentation frontend low
Wikid82/Charon#2149 · 1 asignado ·
Los mantenedores suelen responder en 1 día
Todos los issues de Wikid82/Charon
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
agent:ready
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
turbot/flowpipe#1162 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
LifetimeRemaining divides by zero when expireAfter is 0s, producing NaN disruption costsPosiblemente ocupada @weirong-ui la tomó hoy. Abiertokind/bug needs-priority needs-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
kubernetes-sigs/karpenter#3728 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
compaction: redundant exclusion checks after inRangePosiblemente ocupada @moodbased la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
docker/mcp-registry#8199 ·
Los mantenedores suelen responder en 2 días