devcontainer exec: no error message when Docker is not running on macOS
@v-Kaniska244 is already working on this.
Since Apr 3, 2026.
Assessment
This issue has not been assessed yet.
Description
Problem
When running devcontainer exec command on macOS without Docker Desktop installed or running, the command exits with a non-zero exit code, but no error message is displayed on stderr. This forces developers to guess what went wrong.
Expected Behavior
The application should display a clear error message on stderr explaining that Docker cannot be reached, similar to what the docker CLI does.
Current Behavior
$ devcontainer exec poetry --version
# No output, just exits with code 1
Example of Good Error Messaging
The docker CLI provides helpful feedback:
$ docker ps
Cannot connect to the Docker daemon at unix:///Users/kamil/.docker/run/docker.sock. Is the docker daemon running?
Impact
Poor error messaging negatively affects developer experience (DX). Users can't quickly diagnose issues and must resort to debugging or searching through documentation.
Suggested Solution
When devcontainer exec fails to connect to Docker, it should print a descriptive error message to stderr, similar to:
Error: Cannot connect to Docker daemon. Is Docker Desktop running?
This would significantly improve the user experience and reduce confusion.
- Dominant language
- TypeScript
- Stars
- 3k
- Forks
- 461
- Avg merge
- 13h 17m
- Merged PRs (30d)
- 6
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from devcontainers/cli
-
Difficulty 1/5 Under an hour Newbie friendliness 92/100
devcontainers/cli#1203 ·
-
Difficulty 1/5 1-3 hours Newbie friendliness 68/100
devcontainers/cli#1178 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
devcontainers/cli#1301 ·
-
Difficulty 3/5 1-2 days Newbie friendliness 74/100
devcontainers/cli#1300 ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
devcontainers/cli#1298 ·
All issues in devcontainers/cli
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
linagora/twake-calendar-frontend#1377 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
EclipseFdn/open-vsx.org#13385 · 1 comment ·
-
front-end UI/UX
Difficulty 1/5 Under an hour Newbie friendliness 75/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
S: triage
Difficulty 1/5 Under an hour Newbie friendliness 85/100