Kubernetes executor direct tests fail without envtest assets
Maintainer thường phản hồi trong vòng 2 ngày
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 76/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- go, kubernetes
- Lĩnh vực
- devops, testing-qa
Hướng nghiên cứu
Bắt đầu với pkg/app/piped/executor/kubernetes/sync_test.go, đặc biệt là TestExecutor_ensureSync và phần thiết lập envtest.Environment, sau đó so sánh việc cung cấp asset trong Makefile và target make test/go. Chạy trực tiếp lệnh go test khi KUBEBUILDER_ASSETS chưa được thiết lập. Hoàn tất khi việc thiếu asset envtest tạo ra thông báo skip hoặc setup rõ ràng, trong khi make test/go vẫn chạy test với các asset đã được cung cấp.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
What happened:
Direct package-level Go tests for the Kubernetes executor are not self-contained. Running go test ./pkg/app/piped/executor/kubernetes -run TestExecutor_ensureSync -count=1 without preinstalled envtest assets fails while starting envtest.Environment with exec: "etcd": executable file not found in $PATH or fork/exec /usr/local/kubebuilder/bin/etcd: no such file or directory.
What you expected to happen:
Direct package tests should either bootstrap envtest prerequisites automatically or skip with a clear message when the assets are unavailable, instead of failing as though the executor logic is broken.
How to reproduce it:
- Ensure
KUBEBUILDER_ASSETSis unset and no local envtest binaries are installed. - Run
go test ./pkg/app/piped/executor/kubernetes -run TestExecutor_ensureSync -count=1. - Observe
TestExecutor_ensureSyncfail whileenvtest.Environmentstarts. - Compare that with
make test/go, which installs and exports envtest assets viasetup-envtestinMakefilebefore running the Go tests.
Environment:
pipedversion: repository checkout on 2026-07-11 (upstream/masterfetched tod720a26aduring validation)control-planeversion: Not applicable- Others: reproduced locally during repository assessment
Summary
Direct Go tests for the Kubernetes executor rely on envtest binaries that are only provisioned by the Makefile wrapper.
Affected Area
pkg/app/piped/executor/kubernetes/sync_test.go, Makefile
Expected Behaviour
The test should either provision envtest requirements or skip with a clear environment-related message.
Actual Behaviour
The test fails at envtest startup when envtest binaries are not available.
Technical Evidence
pkg/app/piped/executor/kubernetes/sync_test.gocreatesenvtest.Environmentdirectly and callsStart().Makefileprovisionssetup-envtestand exportsKUBEBUILDER_ASSETSformake test/go.- Reproduced failure:
go test ./pkg/app/piped/executor/kubernetes -run TestExecutor_ensureSync -count=1Error: Received unexpected error: unable to start control plane itself: failed to start the controlplane. retried 5 times: exec: "etcd": executable file not found in $PATH
Suspected Root Cause
The test assumes envtest binaries are already available, but that prerequisite is encoded only in the Make target and not in the test itself.
Proposed Direction
Add an explicit envtest asset preflight in the test so it either uses available binaries or skips with a clear message when the environment is missing the required assets.
Acceptance Criteria
- Direct
go teston the package no longer reports a misleading functional failure when envtest assets are missing. make test/gocontinues to run the test unchanged when envtest assets are provisioned.- Contributors can distinguish environmental setup issues from real executor regressions immediately.
- Ngôn ngữ chính
- Go
- Star
- 1.4k
- Fork
- 391
- Merge trung bình
- 4 ngày 1 giờ
- Pull request đã merge (30 ngày)
- 58
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc 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 pipe-cd/pipecd
-
Applications at the repository root are not triggered by new commitsCó thể đã có người làm @Daksha1611 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 2 ngày
-
pipedv1 kubernetes plugins ignore trafficRouting.istio.host in K8S_TRAFFIC_ROUTINGCó thể đã có người làm @Dhirenderchoudhary đã nhận hôm nay. Đang mở
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 74/100
pipe-cd/pipecd#7626 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 2 ngày
-
pipectl transfer restore application drops backed-up labelsCó thể đã có người làm @bhavishyajain545 đã nhận 1 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
pipe-cd/pipecd#7622 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
Maintainer thường phản hồi trong vòng 2 ngày
Tất cả issue của pipe-cd/pipecd
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày
-
docker-compose: postgres healthcheck should probe TCP (pg_isready -h localhost)Có thể đã có người làm @zezo-mohamed22 đã nhận hôm nay. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 82/100
OneBusAway/watchdog#305 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
self-care self-care:agent-discoverability
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
githubnext/gh-cao#20928 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
automation documentation
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
SocialGouv/iterion#3287 ·
Maintainer thường phản hồi trong vòng 1 ngày