LIFEOS/TOOLS imports hooks/lib in 55 files, against the rule in Paths.ts, so those tools cannot load without the hooks tree

Abierto
#2,864 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 5 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
54/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
bun, typescript

Línea de trabajo

Read LIFEOS/TOOLS/Paths.ts and the imports in DAGrowth.ts, MemoryStatus.ts, and WorkSweep.ts, then inspect hooks/lib/identity.ts, work-config.ts, and lane-rules.ts. Start by checking the reported imports and the --no-hooks install path; verify the proposed move and re-exports work with the reproduction command. Done means TOOLS loads when hooks/ is absent and the Paths.ts dependency rule holds.

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

Descripción

Summary

LIFEOS/TOOLS/Paths.ts:8-10 says TOOLS never depends on the hooks tree, because a TOOLS file
importing hooks/lib broke fresh installs between the DeployCore and InstallHooks steps
(#1974, #1968, #1955). On 94bd8f25, 55 files under LIFEOS/TOOLS import from hooks/lib, most
often identity.ts and work-config.ts. With LIFEOS/TOOLS on disk and hooks/ not there,
DAGrowth.ts fails to load. InstallAll.ts:216 offers --no-hooks for a user who declines hooks;
from reading the installer, that leaves the same state for good (not run end to end).

Where
  • LIFEOS/TOOLS/Paths.ts:10 (the rule)
  • LIFEOS/TOOLS/DAGrowth.ts:18, MemoryStatus.ts:27, WorkSweep.ts:43,46 (WorkSweep.ts:239 restates the rule)
  • hooks/lib/work-config.ts and hooks/lib/lane-rules.ts have no importer inside hooks/: 20 and 9 importers outside it
Repro
git grep -lE "from ['\"](\.\./)+hooks/lib/" HEAD -- LifeOS/install/LIFEOS/TOOLS | wc -l    # 55; Paths.ts implies 0
mkdir -p t/LIFEOS && cp -r LifeOS/install/LIFEOS/TOOLS t/LIFEOS/ && cd t && bun LIFEOS/TOOLS/DAGrowth.ts --help
# error: Cannot find module '../../hooks/lib/identity'
Fix

Root cause: the modules TOOLS needs from the hooks tree (identity, work-config, lane-rules) still
live in hooks/lib/, so the rule in Paths.ts holds only for the one resolver that was moved.
A general fix is to move them into LIFEOS/TOOLS/, as was done for Paths.ts, and leave
hooks/lib/* as one-line re-exports: the install-order break cannot come back, and work-config
and lane-rules then sit next to the code that uses them.

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.