Skip to content

Creating a codespace fails #1025

@adrbin

Description

@adrbin

Describe the bug
An error about incompatibles package versions does not allow to finish creating a codespace.
Full rebuild of the container does not help.

To Reproduce
Steps to reproduce the behavior:

  1. Fork a repository
  2. Click Code -> Create a codespace
  3. Wait for the codespace to initialize

Expected behavior
Codespaces should be created without any errors.

Screenshots

Image

Desktop (please complete the following information):

  • OS: [macOS]
  • Browser [safari]
  • Version [26.1]

Output from the terminal:

Configuration starting...
Cloning...
Using image: mcr.microsoft.com/devcontainers/universal
Creating container...
Cleaning up docker images...
$ devcontainer up --id-label Type=codespaces --workspace-folder /var/lib/docker/codespacemount/workspace/generative-ai-for-beginners --mount type=bind,source=/.codespaces/agent/mount/cache,target=/vscode --user-data-folder /var/lib/docker/codespacemount/.persistedshare --container-data-folder .vscode-remote/data/Machine --container-system-data-folder /var/vscode-remote --log-level trace --log-format json --update-remote-user-uid-default never --mount-workspace-git-root false --omit-config-remote-env-from-metadata --skip-non-blocking-commands --skip-post-create --remove-existing-container --config "/var/lib/docker/codespacemount/workspace/generative-ai-for-beginners/.devcontainer/devcontainer.json" --override-config /root/.codespaces/shared/merged_devcontainer.json --default-user-env-probe loginInteractiveShell --container-session-data-folder /workspaces/.codespaces/.persistedshare/devcontainers-cli/cache --secrets-file /root/.codespaces/shared/user-secrets-envs.json
[177 ms] @devcontainers/cli 0.80.0. Node.js v18.20.6. linux 6.8.0-1030-azure x64.
[748 ms] Start: Run: docker run --sig-proxy=false -a STDOUT -a STDERR --mount type=bind,src=/var/lib/docker/codespacemount/workspace,dst=/workspaces --mount type=volume,src=dind-var-lib-docker-0hcbhh2c7vldoj773drm1bjldnb89u0rt96sl9nju22d9ou8d14n,dst=/var/lib/docker --mount type=volume,src=minikube-config,dst=/home/vscode/.minikube --mount source=/root/.codespaces/shared,target=/workspaces/.codespaces/shared,type=bind --mount source=/var/lib/docker/codespacemount/.persistedshare,target=/workspaces/.codespaces/.persistedshare,type=bind --mount source=/.codespaces/agent/mount,target=/.codespaces/bin,type=bind --mount source=/mnt/containerTmp,target=/tmp,type=bind --mount type=bind,src=/.codespaces/agent/mount/cache,dst=/vscode -l Type=codespaces -e CODESPACES=******** -e ContainerVersion=13 -e RepositoryName=generative-ai-for-beginners -u codespace --cap-add=SYS_PTRACE --security-opt seccomp=unconfined --privileged --init --label CodespacesImageType=Default --label ContainerVersion=13 --hostname codespaces-e6891a --add-host codespaces-e6891a:127.0.0.1 --cap-add sys_nice --network host --init --privileged --cap-add SYS_PTRACE --security-opt seccomp=unconfined --entrypoint /bin/sh -l devcontainer.metadata=[{"id":"ghcr.io/devcontainers/features/common-utils:2"},{"id":"ghcr.io/devcontainers/features/git:1"},{"id":"ghcr.io/devcontainers/features/dotnet:2"},{"id":"ghcr.io/devcontainers/features/hugo:1"},{"id":"ghcr.io/devcontainers/features/node:1"},{"id":"./local-features/nvs"},{"id":"ghcr.io/devcontainers/features/conda:1"},{"id":"./local-features/patch-conda"},{"id":"ghcr.io/devcontainers/features/php:1"},{"id":"ghcr.io/devcontainers/features/ruby:1"},{"id":"ghcr.io/devcontainers/features/java:1"},{"id":"ghcr.io/devcontainers/features/sshd:1","entrypoint":"/usr/local/share/ssh-init.sh"},{"id":"ghcr.io/devcontainers/features/git-lfs:1","postCreateCommand":"/usr/local/share/pull-git-lfs-artifacts.sh"},{"id":"ghcr.io/devcontainers/features/github-cli:1"},{"id":"ghcr.io/devcontainers/features/docker-in-docker:2","privileged":********,"entrypoint":"/usr/local/share/docker-init.sh","mounts":[{"source":"dind-var-lib-docker-${devcontainerId}","target":"/var/lib/docker","type":"volume"}]},{"id":"ghcr.io/devcontainers/features/kubectl-helm-minikube:1","mounts":[{"source":"minikube-config","target":"/home/vscode/.minikube","type":"volume"}]},{"id":"ghcr.io/devcontainers/features/go:1","init":********,"capAdd":["SYS_PTRACE"],"securityOpt":["seccomp=unconfined"]},{"id":"./local-features/jekyll"},{"id":"ghcr.io/devcontainers/features/oryx:1"},{"id":"ghcr.io/devcontainers/features/python:1"},{"id":"./local-features/patch-python"},{"id":"./local-features/machine-learning-packages"},{"id":"./local-features/setup-user"},{"customizations":{"vscode":{"settings":{"go.toolsManagement.checkForUpdates":"local","go.useLanguageServer":********,"go.gopath":"/go","python.defaultInterpreterPath":"/home/codespace/.python/current/bin/python3","jupyter.kernels.filter":[{"path":"/opt/conda/bin/python","type":"pythonEnvironment"},{"path":"/usr/local/python/current/bin/python3","type":"pythonEnvironment"},{"path":"/usr/local/python/current/bin/python","type":"pythonEnvironment"},{"path":"/usr/bin/python3","type":"pythonEnvironment"},{"path":"/bin/python3","type":"pythonEnvironment"}],"lldb.executable":"/usr/bin/lldb"},"extensions":["GitHub.vscode-pull-request-github"]}},"containerUser":"codespace","remoteUser":"codespace"},{"updateContentCommand":"python3 -m pip install -r requirements.txt","postCreateCommand":"bash .devcontainer/post-create.sh","waitFor":"onCreateCommand","customizations":{"codespaces":{"openFiles":[]},"vscode":{"extensions":["ms-python.python","ms-toolsai.jupyter"],"postCreateCommand":["curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh","pip3 --disable-pip-version-check --no-cache-dir install -r requirements.txt"],"settings":{"go.toolsManagement.checkForUpdates":"local","go.useLanguageServer":********,"go.gopath":"/go","python.defaultInterpreterPath":"/home/codespace/.python/current/bin/python3","jupyter.kernels.filter":[{"path":"/opt/conda/bin/python","type":"pythonEnvironment"},{"path":"/bin/python2","type":"pythonEnvironment"},{"path":"/usr/bin/python2","type":"pythonEnvironment"},{"path":"/usr/local/python/current/bin/python3","type":"pythonEnvironment"},{"path":"/usr/local/python/current/bin/python","type":"pythonEnvironment"},{"path":"/usr/bin/python3","type":"pythonEnvironment"},{"path":"/bin/python3","type":"pythonEnvironment"}],"lldb.executable":"/usr/bin/lldb"}}},"mounts":["source=/root/.codespaces/shared,target=/workspaces/.codespaces/shared,type=bind","source=/var/lib/docker/codespacemount/.persistedshare,target=/workspaces/.codespaces/.persistedshare,type=bind","source=/.codespaces/agent/mount,target=/.codespaces/bin,type=bind","source=/mnt/containerTmp,target=/tmp,type=bind"],"containerEnv":{"CODESPACES":"********","ContainerVersion":"13","RepositoryName":"generative-ai-for-beginners"},"remoteUser":"codespace","hostRequirements":{"cpus":4}}] mcr.microsoft.com/devcontainers/universal:2.11.2 -c echo Container started
Unable to find image 'mcr.microsoft.com/devcontainers/universal:2.11.2' locally
2.11.2: Pulling from devcontainers/universal
9ea8908f4765: Pulling fs layer 
abf5c8cf009c: Pulling fs layer 
e290dedb547c: Pulling fs layer 
ccae6c3efbcb: Pulling fs layer 
a80108c02b5f: Pulling fs layer 
6c1ccb34c23c: Pulling fs layer 
1fe9ee707d57: Pulling fs layer 
4f4fb700ef54: Pulling fs layer 
c83c0d97cf7d: Pulling fs layer 
122b61a56162: Pulling fs layer 
b2c50680b23c: Pulling fs layer 
80f0108a6691: Pulling fs layer 
bfdb2a40061d: Pulling fs layer 
eeb49459e532: Pulling fs layer 
1f14f6eb8af3: Pulling fs layer 
9aae999822b8: Pulling fs layer 
0044ed7eea64: Pulling fs layer 
fff596ef7edc: Pulling fs layer 
c30b274b0a59: Pulling fs layer 
c03ea5d4e9f3: Pulling fs layer 
ccae6c3efbcb: Waiting 
d525af0cd746: Pulling fs layer 
33d5c2287dff: Pull complete 
c512b8d10ebe: Pull complete 
0d48a1da67c9: Pull complete 
ef35e3479e77: Pull complete 
e03a119ad747: Pull complete 
ff6cfbbe38b8: Pull complete 
764e5bac9aef: Pull complete 
012cfe96e669: Pull complete 
2c832d68b1b1: Pull complete 
ea99f2a631a2: Pull complete 
db41868ccba0: Pull complete 
ffcdc82620ce: Pull complete 
6271a6a8d8b9: Pull complete 
Digest: sha256:468fdde10b4dcd013ef25228f50631ee9c4488dfcdeeee3777051efd1137ecb4
Status: Downloaded newer image for mcr.microsoft.com/devcontainers/universal:2.11.2
Container started
Outcome: success User: codespace WorkspaceFolder: /workspaces/generative-ai-for-beginners
devcontainer process exited with exit code 0
Running blocking commands...
$ devcontainer up --id-label Type=codespaces --workspace-folder /var/lib/docker/codespacemount/workspace/generative-ai-for-beginners --mount type=bind,source=/.codespaces/agent/mount/cache,target=/vscode --user-data-folder /var/lib/docker/codespacemount/.persistedshare --container-data-folder .vscode-remote/data/Machine --container-system-data-folder /var/vscode-remote --log-level trace --log-format json --update-remote-user-uid-default never --mount-workspace-git-root false --omit-config-remote-env-from-metadata --skip-non-blocking-commands --expect-existing-container --config "/var/lib/docker/codespacemount/workspace/generative-ai-for-beginners/.devcontainer/devcontainer.json" --override-config /root/.codespaces/shared/merged_devcontainer.json --default-user-env-probe loginInteractiveShell --container-session-data-folder /workspaces/.codespaces/.persistedshare/devcontainers-cli/cache --secrets-file /root/.codespaces/shared/user-secrets-envs.json
[191 ms] @devcontainers/cli 0.80.0. Node.js v18.20.6. linux 6.8.0-1030-azure x64.
Outcome: success User: codespace WorkspaceFolder: /workspaces/generative-ai-for-beginners
devcontainer process exited with exit code 0
Configuring codespace...
Running commands...
$ devcontainer up --id-label Type=codespaces --workspace-folder /var/lib/docker/codespacemount/workspace/generative-ai-for-beginners --expect-existing-container --skip-post-attach --mount type=bind,source=/.codespaces/agent/mount/cache,target=/vscode --container-data-folder .vscode-remote/data/Machine --container-system-data-folder /var/vscode-remote --log-level trace --log-format json --update-remote-user-uid-default never --mount-workspace-git-root false --config "/var/lib/docker/codespacemount/workspace/generative-ai-for-beginners/.devcontainer/devcontainer.json" --override-config /root/.codespaces/shared/merged_devcontainer.json --default-user-env-probe loginInteractiveShell --container-session-data-folder /workspaces/.codespaces/.persistedshare/devcontainers-cli/cache --secrets-file /root/.codespaces/shared/user-secrets-envs.json
[213 ms] @devcontainers/cli 0.80.0. Node.js v18.20.6. linux 6.8.0-1030-azure x64.
Running the updateContentCommand from devcontainer.json...

python3 -m pip install -r requirements.txt
Collecting ipywidgets==8.1.7 (from -r requirements.txt (line 1))
  Downloading ipywidgets-8.1.7-py3-none-any.whl.metadata (2.4 kB)
ERROR: Ignored the following versions that require a different python version: 2.3.0 Requires-Python >=3.11; 2.3.1 Requires-Python >=3.11; 2.3.2 Requires-Python >=3.11; 2.3.3 Requires-Python >=3.11; 2.3.4 Requires-Python >=3.11
ERROR: Could not find a version that satisfies the requirement numpy==2.3.4 (from versions: 1.3.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0, 1.6.1, 1.6.2, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.9.1, 1.9.2, 1.9.3, 1.10.0.post2, 1.10.1, 1.10.2, 1.10.4, 1.11.0, 1.11.1, 1.11.2, 1.11.3, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 1.13.3, 1.14.0, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.14.5, 1.14.6, 1.15.0, 1.15.1, 1.15.2, 1.15.3, 1.15.4, 1.16.0, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.16.6, 1.17.0, 1.17.1, 1.17.2, 1.17.3, 1.17.4, 1.17.5, 1.18.0, 1.18.1, 1.18.2, 1.18.3, 1.18.4, 1.18.5, 1.19.0, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.19.5, 1.20.0, 1.20.1, 1.20.2, 1.20.3, 1.21.0, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.22.0, 1.22.1, 1.22.2, 1.22.3, 1.22.4, 1.23.0, 1.23.1, 1.23.2, 1.23.3, 1.23.4, 1.23.5, 1.24.0, 1.24.1, 1.24.2, 1.24.3, 1.24.4, 1.25.0, 1.25.1, 1.25.2, 1.26.0, 1.26.1, 1.26.2, 1.26.3, 1.26.4, 2.0.0, 2.0.1, 2.0.2, 2.1.0, 2.1.1, 2.1.2, 2.1.3, 2.2.0, 2.2.1, 2.2.2, 2.2.3, 2.2.4, 2.2.5, 2.2.6)
ERROR: No matching distribution found for numpy==2.3.4

[notice] A new release of pip is available: 24.1.2 -> 25.3
[notice] To update, run: pip install --upgrade pip
[3177 ms] updateContentCommand from devcontainer.json failed with exit code 1. Skipping any further user-provided commands.

Error: Command failed: /bin/sh -c python3 -m pip install -r requirements.txt
{"outcome":"error","message":"Command failed: /bin/sh -c python3 -m pip install -r requirements.txt","description":"updateContentCommand from devcontainer.json failed.","containerId":"917a7a41ce64ab08b43cca7ff38d1042398e0deed427e4175b44e009d6fbbd32"}
    at E (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:235:157)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Promise.allSettled (index 0)
    at async b9 (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:237:119)
    at async ND (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:226:4668)
    at async RD (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:226:4013)
    at async MD (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:226:3089)
    at async Zg (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:226:2623)
    at async m6 (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:467:1526)
    at async ax (/.codespaces/agent/bin/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:467:960)
devcontainer process exited with exit code 1
Finished configuring codespace.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions