{"record":{"id":"942d426e34e3a0bd","repo":"vxcontrol/pentagi","slug":"failed-to-get-installer-handler-w","errorCode":null,"errorMessage":"failed to get installer handler: %w","messagePattern":"failed to get installer handler: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"backend/pkg/providers/assistant.go","lineNumber":177,"sourceCode":"\t\treturn fmt.Errorf(\"failed to unmarshal primary agent msg chain %d: %w\", ap.msgChainID, err)\n\t}\n\n\tadviser, err := ap.fp.GetAskAdviceHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get ask advice handler\")\n\t\treturn fmt.Errorf(\"failed to get ask advice handler: %w\", err)\n\t}\n\n\tcoder, err := ap.fp.GetCoderHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get coder handler\")\n\t\treturn fmt.Errorf(\"failed to get coder handler: %w\", err)\n\t}\n\n\tinstaller, err := ap.fp.GetInstallerHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get installer handler\")\n\t\treturn fmt.Errorf(\"failed to get installer handler: %w\", err)\n\t}\n\n\tmemorist, err := ap.fp.GetMemoristHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get memorist handler\")\n\t\treturn fmt.Errorf(\"failed to get memorist handler: %w\", err)\n\t}\n\n\tpentester, err := ap.fp.GetPentesterHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get pentester handler\")\n\t\treturn fmt.Errorf(\"failed to get pentester handler: %w\", err)\n\t}\n\n\tsearcher, err := ap.fp.GetSubtaskSearcherHandler(ctx, nil, nil)\n\tif err != nil {\n\t\tlogger.WithError(err).Error(\"failed to get searcher handler\")\n\t\treturn fmt.Errorf(\"failed to get searcher handler: %w\", err)","sourceCodeStart":159,"sourceCodeEnd":195,"githubUrl":"https://github.com/vxcontrol/pentagi/blob/ea665308baaff015b226f308438a68d929d0f29b/backend/pkg/providers/assistant.go#L159-L195","documentation":"Wraps a failure from fp.GetInstallerHandler during assistant worker setup (backend/pkg/providers/assistant.go). The installer agent's LLM handler could not be constructed, typically due to an unavailable or misconfigured LLM provider. The assistant worker cannot start without it.","triggerScenarios":"Installer handler factory fails: Docker client error (it installs packages in the sandbox), missing tool configuration, or dependent DB/template lookups error.","commonSituations":"Docker unavailable in the deployment (rootless setups, socket not mounted); incomplete .env after manual install; sandbox image pull failure during handler warm-up.","solutions":["Verify Docker access from the backend container (mount /var/run/docker.sock or set DOCKER_HOST).","Pre-pull the sandbox image and check registry connectivity.","Fill the missing env config per .env.example and restart.","Read the wrapped error in logs to pinpoint the failing dependency."],"exampleFix":"// before\ninstaller, err := ap.fp.GetInstallerHandler(ctx, nil, nil)\nif err != nil {\n    return fmt.Errorf(\"failed to get installer handler: %w\", err)\n}\n// after\ninstaller, err := ap.fp.GetInstallerHandler(ctx, &taskID, &subtaskID)\nif err != nil {\n    return fmt.Errorf(\"failed to get installer handler: %w\", err) // typically docker socket or sandbox image issue\n}","handlingStrategy":"validation","validationCode":"cli, err := client.NewClientWithOpts(client.FromEnv)\nif err != nil { return fmt.Errorf(\"docker unavailable for installer handler: %w\", err) }\nif _, err := cli.ImageInspect(ctx, sandboxImage); err != nil { return fmt.Errorf(\"sandbox image missing: %w\", err) }","typeGuard":null,"tryCatchPattern":"installer, err := ap.fp.GetInstallerHandler(ctx, nil, nil)\nif err != nil {\n    logger.WithError(err).Error(\"installer handler init failed\")\n    return fmt.Errorf(\"failed to get installer handler: %w\", err)\n}","preventionTips":["Ensure the Docker socket is mounted and permissioned","Pre-pull sandbox images to avoid registry outages","Keep DOCKER_HOST consistent between compose services","Complete tool env configuration before starting flows"],"tags":["docker","tools","handler-init"],"backgroundTag":"tool-handler-init-failed","analyzedSha":"ea665308baaff015b226f308438a68d929d0f29b","analyzedAt":"2026-09-01T14:16:31.421Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}