kbuild: skip building kselftest when not required by jobfilter (speed up bisection)
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 50/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- python
- Lĩnh vực
- build-system, ci-cd
Hướng nghiên cứu
Bắt đầu với get_jobfilter() trong src/lava_callback.py, sau đó kiểm tra config/jobs.yaml và config/scheduler.yaml để lần theo các bài kiểm thử kselftest qua các liên kết sự kiện đến các build job tương ứng. So sánh điều này với logic lọc hiện tại trong kernelci/kbuild.py. Hoàn thành khi các kselftest job được yêu cầu vẫn giữ lại các artifact cần thiết, trong khi các bản build bisection không liên quan bỏ qua kselftest.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Goal
To speed up bisection, do not build kselftest when it isn't needed by the requested jobs (kselftest builds are expensive and dominate bisection turnaround).
This was originally attempted in #2729, but that approach needs more design work before it can land — see below. Converting to an issue to track the proper solution.
Current attempt (#2729)
In kernelci/kbuild.py, when a jobfilter is present, kselftest is disabled unless <build-name>-kselftest literally appears in the filter:
if node['jobfilter'] and self._kfselftest is True:
kselftest_name = node['name'] + "-kselftest"
if kselftest_name not in node['jobfilter']:
self._kfselftest = False
Why this isn't enough
-
Downstream tests are invisible to the build.
kbuild.pyruns in the build container and only receivesnode+params+ a flatjobfilterlist of strings. It has no knowledge of which tests consume kselftest artifacts. So a jobfilter containing a kselftest test (but not the kselftest build name) would silently produce a build without kselftest, and the test would fail mysteriously. The dependency knowledge lives in kernelci-pipeline:- test → needs-kselftest is identifiable from
config/jobs.yaml(test_method: kselftest,kcidb_test_suite: kselftest.*) - build → test link is the
eventfield inconfig/scheduler.yaml
- test → needs-kselftest is identifiable from
-
Possible naming bug. Dedicated kselftest build variants are already named
kbuild-...-kselftest(e.g.config/jobs.yaml,scheduler.yaml). For such a node,node['name'] + "-kselftest"becomeskbuild-...-kselftest-kselftest, which never matches the filter — so kselftest would be disabled on the very build meant to produce it (this is exactly the bisection-of-a-kselftest-test path). Needs verification against realnode['name']values.
Proposed direction
Move the decision to kernelci-pipeline, which already has self._configs loaded and builds the jobfilter in get_jobfilter() (src/lava_callback.py):
- When any requested job in the jobfilter resolves to a kselftest test (
test_method == 'kselftest'), auto-enable kselftest on the corresponding build (e.g. set akselftest: enableparam on the build node, or ensure the kselftest-enabled build name is in the filter). - Otherwise, leave kselftest off so bisection builds stay fast.
The one non-trivial piece is reverse-resolving the scheduler graph (test → triggering build-node event → build job), since the build job doesn't inherently know its downstream tests. This is an in-memory config walk, not new infrastructure.
Closes #2729 (superseded by this issue).
- Ngôn ngữ chính
- Python
- Star
- 120
- Fork
- 108
- Merge trung bình
- 1 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 21
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
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 kernelci/kernelci-core
-
good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
kernelci/kernelci-core#2591 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 25/100
kernelci/kernelci-core#3234 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Make Kubernetes job network readiness checks bounded and deployment-independentCó thể làm lại được @Aniket1260 đã nhận 38 ngày trước và không có pull request nào đang mở. Đang mởgood first issue techdebt
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
kernelci/kernelci-core#3197 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
chromeos techdebt
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
kernelci/kernelci-core#3196 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
kubernetes runners missing logs and test naming wrongCó thể làm lại được @nuclearcat đã nhận 70 ngày trước và không có pull request nào đang mở. Đang mở
kernelci/kernelci-core#3170 · 2 bình luận · 1 reaction · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của kernelci/kernelci-core
Issue tương tự
-
first
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
AcademySoftwareFoundation/rmtc#54 · 1 bình luận ·
-
feature/cohorts feature/feature-flags team/feature-flags
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
Maintainer thường phản hồi trong vòng 1 ngày
-
License examples/ as MITCó thể đã có người làm @PGrayCS đã nhận hôm nay. Đang mởdocumentation enhancement example good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
speedyk-005/yasbd-lib#383 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
interactions-py/interactions.py#1827 ·
-
Managed start can fail when OpenVMM reads its control capability before NVX writes itCó thể đã có người làm @ppenna đã nhận hôm nay. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày