{"record":{"id":"7246af1c15918b29","repo":"jesseduffield/lazydocker","slug":"cannot-proceed-until-docker-gives-us-more-informat","errorCode":null,"errorMessage":"Cannot proceed until docker gives us more information about the container. Please retry in a few moments.","messagePattern":"Cannot proceed until docker gives us more information about the container\\. Please retry in a few moments\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"pkg/commands/container.go","lineNumber":93,"sourceCode":"\treturn c.Client.ContainerPause(context.Background(), c.ID)\n}\n\n// Unpause unpauses the container\nfunc (c *Container) Unpause() error {\n\tc.Log.Warn(fmt.Sprintf(\"unpausing container %s\", c.Name))\n\treturn c.Client.ContainerUnpause(context.Background(), c.ID)\n}\n\n// Restart restarts the container\nfunc (c *Container) Restart() error {\n\tc.Log.Warn(fmt.Sprintf(\"restarting container %s\", c.Name))\n\treturn c.Client.ContainerRestart(context.Background(), c.ID, container.StopOptions{})\n}\n\n// Attach attaches the container\nfunc (c *Container) Attach() (*exec.Cmd, error) {\n\tif !c.DetailsLoaded() {\n\t\treturn nil, errors.New(c.Tr.WaitingForContainerInfo)\n\t}\n\n\t// verify that we can in fact attach to this container\n\tif !c.Details.Config.OpenStdin {\n\t\treturn nil, errors.New(c.Tr.UnattachableContainerError)\n\t}\n\n\tif c.Container.State == \"exited\" {\n\t\treturn nil, errors.New(c.Tr.CannotAttachStoppedContainerError)\n\t}\n\n\tc.Log.Warn(fmt.Sprintf(\"attaching to container %s\", c.Name))\n\t// TODO: use SDK\n\tcmd := c.OSCommand.NewCmd(\"docker\", \"attach\", \"--sig-proxy=false\", c.ID)\n\treturn cmd, nil\n}\n\n// Top returns process information","sourceCodeStart":75,"sourceCodeEnd":111,"githubUrl":"https://github.com/jesseduffield/lazydocker/blob/7e7aadc2071d58031bf2daafca1fbd4093efc23f/pkg/commands/container.go#L75-L111","documentation":"Thrown by Container.Attach() when c.DetailsLoaded() is false, meaning lazydocker has not yet received the container's inspect payload from the Docker daemon. It is a transient guard: the container exists in the list, but its full Config/State (fetched asynchronously) has not arrived yet. The message (c.Tr.WaitingForContainerInfo) explicitly asks the user to retry in a few moments rather than signaling permanent failure.","triggerScenarios":"Calling Container.Attach() right after lazydocker starts, immediately after the container list refreshes, or right after a container is created, before the background Inspect() call that populates c.Details completes.","commonSituations":"User presses 'a' (attach) on a freshly-listed container within the first moments of the UI loading; attaching to a container that was just created via docker run from another terminal; slow Docker daemon over a remote DOCKER_HOST causing inspect to lag behind listing.","solutions":["Wait a few seconds and retry the attach action — the details usually populate within one refresh cycle.","If it persists, verify the Docker daemon is responsive (docker ps, docker inspect <id>) — a hung daemon never populates details.","Check connectivity to remote/SSH Docker hosts; a slow or dropping connection delays the inspect call indefinitely.","As a code-level fix, poll DetailsLoaded() with a short timeout before invoking Attach()."],"exampleFix":"// before\ncmd, err := container.Attach()\nif err != nil {\n    return err\n}\n\n// after\n deadline := time.Now().Add(5 * time.Second)\nfor !container.DetailsLoaded() {\n    if time.Now().After(deadline) {\n        return err\n    }\n    time.Sleep(100 * time.Millisecond)\n}\ncmd, err := container.Attach()\nif err != nil {\n    return err\n}","handlingStrategy":"retry","validationCode":"// before attaching, wait for details to load\nfor i := 0; i < 50 && !container.DetailsLoaded(); i++ {\n    time.Sleep(100 * time.Millisecond)\n}\nif !container.DetailsLoaded() {\n    return fmt.Errorf(\"container details not available yet\")\n}","typeGuard":null,"tryCatchPattern":"err := retry(3, 500*time.Millisecond, func() error { _, err := container.Attach(); return err })\nif err != nil { /* only surface after retries exhausted */ }","preventionTips":["Treat this message as transient: retry the attach after one UI refresh cycle before assuming failure.","When scripting, always gate on DetailsLoaded() (or a successful Inspect) before attach-dependent operations.","Keep the Docker daemon connection healthy; slow daemons prolong the window in which this error can occur."],"tags":["docker","transient","container-attach","race-condition"],"backgroundTag":null,"analyzedSha":"7e7aadc2071d58031bf2daafca1fbd4093efc23f","analyzedAt":"2026-08-15T09:51:48.093Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}