async-cache-single-flight: the selection regex matches `constants.set(` as `s.set(` and the law card's own example text

Abierto
#437 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
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
53/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
typescript
Área
testing-qa

Línea de trabajo

Start with the gate regex in async-cache-single-flight.ts:72-77 and the cited matches in ts-model.ts:714 and cache-harness-laws.ts:83-85. Read how audit-engine.ts:278 represents its disk JSON cache, then check the gate against those examples and the in-memory map case. Done means the gate avoids the false matches described in the issue and still selects the intended single-flight cases.

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

Descripción

bug

Found in the 8.0.0 self-audit triage: RoC 7.29.1 (npm, 5fc54afe) on a clean clone of develop at 2d2fa9a, with typescript resolvable (verdict compliance, 0 failed / 46 warnings). The bucket method and per-law tables are kept by QA; counts are from that run.

What happens

The gate regex (async-cache-single-flight.ts:72-77) back-references the map name with \1 but has no left boundary, so s.set( matches inside constants.set( (ts-model.ts:714); a law registry file is selected by the card's own example (cache-harness-laws.ts:83-85). The single finding in RoC (audit-engine.ts:278) is a disk JSON cache: a promise cannot be stored there and concurrent callers of a CLI audit are separate processes — a different concurrency model than the in-memory map the law is about.

Suggested direction

Word boundary before the back-reference; skip string contents (M1); recognise disk/JSON caches as outside the in-memory single-flight concern.

Lenguaje dominante
TypeScript
Estrellas
0
Forks
0
Merge medio
38 min
PR fusionados (30 d)
96

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 Rule-Of-Code/RoC

Todos los issues de Rule-Of-Code/RoC

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.