thedotmack/claude-mem · warning
Dependency preflight found degraded optional setup
Error message
Dependency preflight found degraded optional setup
What it means
During background initialization the worker runs a dependency preflight (runWorkerDependencyPreflight) checking optional components (e.g. Chroma/Python via uv, claude CLI classification). If any optional dependency reports degraded, the worker logs a warning listing each degraded dependency but continues running with reduced functionality.
Solutions
- Read the `statuses` array in the log to see which dependency is degraded and its message.
- Install the missing tool (e.g. install uv or bun per claude-mem requirements) and ensure it is on the worker's PATH.
- Restart the worker so preflight re-runs and the dependency initializes.
- If the degraded dependency is genuinely optional for your use, acknowledge and continue — the warning is non-fatal.
Example fix
// before: worker started without uv on PATH # systemctl start claude-mem-worker // after: ensure PATH includes uv install dir Environment="PATH=/home/user/.local/bin:/usr/local/bin:/usr/bin:/bin"
Defensive patterns
Strategy: fallback
Validate before calling
for (const bin of ['bun','uv','node']) {
if (!which(bin)) console.warn(`Optional dependency missing: ${bin}`);
} Prevention
- Install all requirements (bun, uv, node) before first worker start
- Ensure the service unit (launchd/systemd/docker) inherits your shell PATH
- Re-run preflight after OS or dependency upgrades
When it happens
Trigger: initializeBackground (called from start) finds dependencyHealth.degraded === true — e.g. uv/Python missing so Chroma cannot launch, or an optional binary not on PATH.
Common situations: Fresh install where uv or bun was never installed; PATH differences when the worker runs under launchd/systemd vs a shell; upgraded OS dropping a Python version; Docker image missing an optional layer.
Understand the failure class
Background: "X is not installed. Please install it with pip install Y": missing optional dependency errors — ImportError/ValueError raised when a library's optional extra was never installed — this error's family across 22 libraries.
Related errors
- bun install failed in
- Cannot process observations: memorySessionId not yet…
- Cannot process summary: memorySessionId not yet captured…
- Context requested before initialization complete, returning…
- Invalid CLAUDE_MEM_QUEUE_ENGINE=
AI-assisted analysis of thedotmack/claude-mem@d8bc9755e7 (2026-09-17).
Data as JSON: /api/errors/6671a680617390e7.
Report an issue: GitHub.
Appendix: source
Thrown at src/services/worker-service.ts:535
try {
logger.info('WORKER', 'Background initialization starting...');
const { ModeManager } = await import('./domain/ModeManager.js');
const { SettingsDefaultsManager } = await import('../shared/SettingsDefaultsManager.js');
const { USER_SETTINGS_PATH } = await import('../shared/paths.js');
const settings = SettingsDefaultsManager.loadFromFile(USER_SETTINGS_PATH);
const modeId = settings.CLAUDE_MEM_MODE;
ModeManager.getInstance().loadMode(modeId);
logger.info('SYSTEM', `Mode loaded: ${modeId}`);
const dependencyHealth = runWorkerDependencyPreflight({
settings,
classifyClaudeError,
});
if (dependencyHealth.degraded) {
logger.warn('SYSTEM', 'Dependency preflight found degraded optional setup', {
statuses: dependencyHealth.statuses.map(status => ({
dependency: status.dependency,
kind: status.kind,
message: status.message,
})),
});
} else {
logger.info('SYSTEM', 'Dependency preflight passed');
}
logger.info('WORKER', 'Checking for one-time CWD remap...');
runOneTimeCwdRemap();
const chromaEnabled = settings.CLAUDE_MEM_CHROMA_ENABLED !== 'false';
if (chromaEnabled) {
this.chromaMcpManager = ChromaMcpManager.getInstance();
logger.info('SYSTEM', 'ChromaMcpManager initialized (lazy - connects on first use)');
} else {View on GitHub (pinned to d8bc9755e7)