Fix/doctor engine level and test deps #2

Merged
gsalucci merged 2 commits from fix/doctor-engine-level-and-test-deps into main 2026-08-27 15:52:35 +02:00
Collaborator
No description provided.
gsalucci added 2 commits 2026-08-27 15:52:30 +02:00
The resident gRPC daemon is an optimisation, not a requirement:
draw-things-cli works fine cold (it just reloads 6GB of weights per call)
and index.ts's waitForServer() warms it on the first generation anyway.
A doctor that lists the engine under 'Qualcosa non va' makes a working
install look broken every morning and pushes the user to chase a non-issue.

All four reachable branches of checkServer — disabled, binaryMissing,
notExecutable, stopped — now return level: 'info'. The fix hint stays in
the report so the user can still copy the manual start command when they
want to.
'npm run test:e2e' was failing before it even started:
the four tests import { createJiti } from 'jiti' but jiti was never
declared in package.json, so Node threw ERR_MODULE_NOT_FOUND on the
first import. Adding it to devDependencies fixes the loader.

The same tests hard-coded the original developer's path
('/home/moze/Sorgenti/pi-imgen'), so even with jiti installed they
would have failed on any other checkout. Replacing it with
dirname(dirname(dirname(fileURLToPath(import.meta.url)))) lets the
suite run from wherever the repo is cloned.
gsalucci merged commit b5badf7fce into main 2026-08-27 15:52:35 +02:00
gsalucci deleted branch fix/doctor-engine-level-and-test-deps 2026-08-27 15:52:35 +02:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mozempk/pi-imgen#2