[bug] slugFromPath in hooks/lib/isa-utils.ts compares raw paths, so a file touched by…

Abierto Apto para principiantes
#2,940 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 4 días

Nadie ha tomado este issue todavía.

Evaluación

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

Línea de trabajo

Empieza en hooks/lib/isa-utils.ts:1099, donde a lifeosPath('MEMORY','WORK') se le añade un prefijo y se compara con startsWith, luego sigue al llamador en EventLogger.hook.ts:286-290 para ver los incrementos de la misma sesión frente a los de sesiones distintas. Copia el enfoque usado para #2721 (KnowledgeWriteGuard) y la comprobación de WORK/WORK_REAL en LIFEOS/TOOLS/IsaLadder.ts:146: resuelve los symlinks en ambos lados antes de comparar. Hecho significa que ambas llamadas del informe devuelven x — la ruta MEMORY con symlink y el realpath —, sin regresión para rutas MEMORY/WORK simples.

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

Descripción

What happened

slugFromPath misses files touched by their real path behind the LIFEOS/MEMORY symlink

Summary

hooks/lib/isa-utils.ts:1099 builds lifeosPath('MEMORY', 'WORK') + '/' and tests the tool's file_path with startsWith. The installer makes LIFEOS/MEMORY a symlink into the per-user tree (skills/LifeOS/Tools/InstallEngine.ts:1139), so a path given by the real target of that symlink (<realpath of LIFEOS/MEMORY>/WORK/<slug>/...) returns null, and EventLogger.hook.ts:290 (bumpLastToolActivity(toolFilePath)) skips the cross-session heartbeat for that slug. The same-session bump at :286 is unaffected.

Same class as #2721 (KnowledgeWriteGuard), fixed there by resolving symlinks on both sides. LIFEOS/TOOLS/IsaLadder.ts:146 already handles this by checking WORK and WORK_REAL. To see it: slugFromPath("<claude>/LIFEOS/MEMORY/WORK/x/ISA.md") -> "x", slugFromPath("<realpath of LIFEOS/MEMORY>/WORK/x/ISA.md") -> null.

Details

  • Kind: bug
  • LifeOS version: 8.761.0

Filed with the LifeOS /feedback command. The reporter approved this exact text before it was sent; paths, secrets and personal details were stripped locally.

Lenguaje dominante
TypeScript
Estrellas
19.9k
Forks
2.5k
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

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 danielmiessler/LifeOS

Todos los issues de danielmiessler/LifeOS

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.