{"record":{"id":"40a017a7b1d56ca9","repo":"juanfont/headscale","slug":"logging-out-stdout-s-stderr-s","errorCode":null,"errorMessage":"logging out, stdout: %s, stderr: %s","messagePattern":"logging out, stdout: (.+?), stderr: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"integration/tsic/tsic.go","lineNumber":770,"sourceCode":"\n\tloginURL, err := util.ParseLoginURLFromCLILogin(stdout + stderr)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn loginURL, nil\n}\n\n// Logout runs the logout routine on the given Tailscale instance.\nfunc (t *TailscaleInContainer) Logout() error {\n\t_, _, err := t.Execute([]string{tailscaleBin, \"logout\"})\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tstdout, stderr, _ := t.Execute([]string{tailscaleBin, \"status\"})\n\tif !strings.Contains(stdout+stderr, \"Logged out.\") {\n\t\treturn fmt.Errorf(\"logging out, stdout: %s, stderr: %s\", stdout, stderr) //nolint:err113\n\t}\n\n\treturn t.waitForBackendState(\"NeedsLogin\", integrationutil.PeerSyncTimeout())\n}\n\n// Restart restarts the Tailscale container using Docker API.\n// This simulates a container restart (e.g., docker restart or Kubernetes pod restart).\n// The container's entrypoint will re-execute, which typically includes running\n// \"tailscale up\" with any auth keys stored in environment variables.\nfunc (t *TailscaleInContainer) Restart() error {\n\tif t.container == nil {\n\t\treturn errContainerNotInitialized\n\t}\n\n\t// Use Docker API to restart the container\n\terr := t.pool.Client.RestartContainer(t.container.Container.ID, 30)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"restarting container %s: %w\", t.hostname, err)","sourceCodeStart":752,"sourceCodeEnd":788,"githubUrl":"https://github.com/juanfont/headscale/blob/565fd254d06c4c7f9a8cad1714a43445c79ba420/integration/tsic/tsic.go#L752-L788","documentation":"Error \"logging out, stdout: %s, stderr: %s\" thrown in juanfont/headscale.","triggerScenarios":"Thrown at integration/tsic/tsic.go:770 when the library encounters an invalid state.","commonSituations":"'tailscale logout' inside the container failed. The captured stdout/stderr show the client-side reason.","solutions":["Inspect the wrapped error for the underlying cause and correct the failing condition (logging out, stdout); retry the operation after fixing the input, configuration, or environment."],"exampleFix":"Inspect the wrapped error for the underlying cause and correct the failing condition (logging out, stdout); retry the operation after fixing the input, configuration, or environment.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"565fd254d06c4c7f9a8cad1714a43445c79ba420","analyzedAt":"2026-08-15T13:12:30.133Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}