TypeError: Cannot read properties of null (reading 'Env')
@v-Kaniska244 đang làm issue này rồi.
Từ ngày 29/4/2025.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
Getting this error suddenly from CLI/Vscode/Cursor:
➜ devcontainer build --workspace-folder . --config .devcontainer/devcontainer.json --image-name=test
[3 ms] @devcontainers/cli 0.75.0. Node.js v20.12.2. darwin 24.3.0 arm64.
TypeError: Cannot read properties of null (reading 'Env')
at o6 (/Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:393:20372)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async y6 (/Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:467:2352)
at async dw (/Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:467:1886)
at async R7 (/Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:667:2203)
at async S7 (/Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:666:4937)
at async /Users/jasondamour/.nvm/versions/node/v20.12.2/lib/node_modules/@devcontainers/cli/dist/spec-node/devContainersSpecCLI.js:484:1188
{"outcome":"error","message":"Cannot read properties of null (reading 'Env')","description":"An error occurred building the container."}
With the dockerfile:
FROM mcr.microsoft.com/devcontainers/base:1.2-ubuntu-22.04
Given I haven't upgraded the CLI in a while and this was working fine recently, I believe this is caused by a change to the base Docker image. Semi-confirmed by changing my base image to ubuntu:22.04 and it worked fine.
However, going to use this repo for the issue. If an image doesn't have an Env property, shouldn't the CLI still succeed?
- Ngôn ngữ chính
- TypeScript
- Star
- 3k
- Fork
- 461
- Merge trung bình
- 18 phút
- Pull request đã merge (30 ngày)
- 5
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của devcontainers/cli
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
devcontainers/cli#1203 ·
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 68/100
devcontainers/cli#1178 · 1 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
devcontainers/cli#1308 ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 78/100
devcontainers/cli#1307 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
devcontainers/cli#1305 ·
Tất cả issue của devcontainers/cli
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
bug v2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
modelcontextprotocol/inspector#2458 · 1 bình luận ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
railmapgen/rmp-gallery#4068 ·
-
Mend: dependency security vulnerability status: needs triage 🕵️♀️
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
carbon-design-system/ibm-products#9907 ·