Ansible/Kubernetes: helm-unittest suites in charts/*/unittests via ct.yaml additional-commands, yamllint as an Ansible linter, molecule's pytest verifier, antsibull-nox
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 22/100
研究方向
Start with project_validator/ecosystems/kubernetes.py around lines 116-118, where the helm-unittest pattern is defined, and with the docs/ecosystems/ansible.md note on yamllint. The issue asks for several separate changes: reading chart-testing's ct.yaml additional-commands, widening the unittests/ pattern, crediting shellcheck and yamllint, and recognising antsibull-nox sessions. Each needs a design decision first, so confirm the scope with a maintainer. Done means the corpus cases for these repositories produce the expected statuses.
由索引模型根據 Issue 內容生成。
描述
prometheus-community/helm-charts runs 118 helm-unittest suites (charts/*/unittests/**/*.yaml) and shellcheck through chart-testing's ct.yaml additional-commands (helm unittest --strict …); the config file is never read and the pattern requires tests/*_test.yaml. yamllint is the one linter every Ansible role in the corpus runs (yamllint ., pre-commit hook, run_yamllint = true) but is not an Ansible static-analysis claim. kubespray's one Python "test" is a molecule/testinfra verifier that molecule test runs. community.general's entire CI is antsibull-nox (declared in the repo's own config), the standard driver of ~100 ansible-collections repos.
Evidence from the corpus audit
ansible-collections/community.general / tests-run, static-analysis, type-checking, code-formatting
- kind: UNSUPPORTED
- actual: ERROR (strict) "not read: job ansible-test: it calls the reusable workflow
ansible-community/antsibull-nox/.github/workflows/reusable-nox-matrix.yml@main"; with--allow-unknown:
tests-runFAIL "Ansible: tests found in 281 file(s), but no CI configuration runs molecule test or ansible-test
integration",static-analysisFAIL "Ansible: ansible-lint is configured (.ansible-lint) but does not run; Python:
ruff check is configured (ruff.toml) but does not run",type-checkingWARN "mypy is configured (.mypy.ini) but
does not run",code-formattingFAIL "Python: ruff.toml is defined but CI does not run ruff format". - expected: the reusable workflow is unreadable (see "Unreadable by nature"), but everything it runs is declared in
the repository's own antsibull-nox configuration, the standard CI driver of the ansible-collections organisation
(~100 collections). Recognisingantsibull-nox.tomlsessions ([sessions.ansible_lint],
[sessions.ansible_test_sanity],[sessions.ansible_test_units],[sessions.ansible_test_integration],
run_mypy = true,run_ruff_check = true,run_ruff_format = true,run_yamllint = true) when the workflow
uses: ansible-community/antsibull-nox/...would answer all four checks. - evidence:
.github/workflows/nox.yml:28:uses: ansible-community/antsibull-nox/.github/workflows/reusable-nox-matrix.yml@main;
antsibull-nox.toml:[sessions.lint]...run_ruff_check = true/run_ruff_format = true/run_yamllint = true
/run_mypy = true/mypy_config = ".mypy.ini";[sessions.ansible_lint];[sessions.ansible_test_sanity];
[sessions.ansible_test_units]with[sessions.ansible_test_units.core_python_versions] "2.19" = ["3.8", "3.11", "3.13"];
[sessions.ansible_test_integration];noxfile.pypresent at the root. - repro:
galaxy.yml+antsibull-nox.tomlwith[sessions.ansible_test_units]+ a workflow whose jobuses: ansible-community/antsibull-nox/.github/workflows/reusable-nox-matrix.yml@main. - confidence: medium (a gap, not a bug)
kubernetes-sigs/kubespray / tests-run (Python)
- kind: FALSE_POSITIVE
- actual: FAIL (component) "Python: the root: tests found in 1 file(s), but no CI configuration runs pytest, unittest
or nox" - expected: the one file is a molecule/testinfra verifier that
molecule testruns (molecule'sverifystage
invokes pytest onmolecule/<scenario>/tests/test_*.py); CI runs molecule (tests/scripts/molecule_run.shfrom
.gitlab-ci/molecule.yml), and the Ansible component of the same check is credited ("Ansible: tests found in 9
file(s)"). Test files undermolecule/*/tests/belong to the molecule scenario, not to a pytest suite. - evidence:
find . -name 'test_*.py' -o -name '*_test.py'→ only
./roles/bootstrap_os/molecule/default/tests/test_default.py;roles/bootstrap_os/molecule/default/molecule.yml
present (scenario). - repro:
molecule/default/molecule.yml+molecule/default/tests/test_default.py+ CImolecule test. - confidence: low (molecule ≥ 6 made the testinfra verifier optional, so whether it runs depends on the scenario's
verifier:; the scenario here declares none in the lines read)
prometheus-community/helm-charts / tests-run, static-analysis (Shell)
- kind: FALSE_NEGATIVE
- actual:
tests-run"Kubernetes: tests found in 11 file(s)" (7templates/tests/*.yamlhooks + the few
tests/*_test.yaml);static-analysisFAIL "Shell: no static analyzer runs";compiler-warningsFAIL "Shell: no
shell lints found";warnings-as-errorsFAIL. - expected: 118 helm-unittest suites under
charts/*/unittests/**/*.yamlcounted and credited as run, and shellcheck
credited: chart-testing's configuration file runshelm unittest --strictandshellcheckon every changed chart
throughadditional-commands, andct lint --config .github/linters/ct.yamlruns in CI. The validator neither
reads ct's config file (.github/linters/ct.yaml/ct.yaml, the only placeadditional-commandscan live) nor
recognisesunittests/as a helm-unittest directory (its pattern requirestests/*_test.yaml). - evidence:
.github/linters/ct.yaml:2-4:additional-commands:/
- sh -ec "if [ -f '{{ .Path }}/ci/lint.sh' ]; then shellcheck '{{ .Path }}/ci/lint.sh'; bash '{{ .Path }}/ci/lint.sh'; fi"/
- helm unittest --strict --file 'unittests/**/*.yaml' {{ .Path }};.github/workflows/ci.yaml:76:
run: ct lint --config .github/linters/ct.yaml;:63:run: helm plugin install https://github.com/helm-unittest/helm-unittest.git ...;
find charts -path '*unittests/*_test.yaml' | wc -l→ 118 (e.g.charts/prometheus-rabbitmq-exporter/unittests/service_test.yaml,
charts/prometheus-stackdriver-exporter/unittests/deployment_namespace_test.yaml).
Validator:project_validator/ecosystems/kubernetes.py:116-118:name="helm-unittest tests (tests/*_test.yaml)",
path=re.compile(r"(?:^|/)tests/.+_test\.ya?ml$"); no reference toadditional-commandsorct.yamlanywhere
inproject_validator/. - repro:
charts/a/Chart.yaml+charts/a/unittests/deployment_test.yaml(suite: ...) +ct.yamlwith
additional-commands: [helm unittest --strict --file 'unittests/**/*.yaml' {{ .Path }}]+ a workflow
run: ct lint --config ct.yaml. - confidence: high
geerlingguy/ansible-role-docker, geerlingguy/ansible-for-devops, kubernetes-sigs/kubespray / static-analysis
- kind: UNSUPPORTED
- actual: ansible-role-docker
static-analysisWARN "ansible-lint is configured (.ansible-lint) but does not run"
(correct, see below) anddata-wellformedPASS "22 YAML files parse" with no mention of yamllint;
kubespray/pre-commit runs yamllint,ansible-static-lint(astl), misspell and a Jinja syntax check that are not
credited anywhere. - expected: not a wrong status, but yamllint is the one linter that every Ansible role in this batch runs
(yamllint .in ansible-role-docker's CI,pip3 install ... yamllintin ansible-for-devops, a pre-commit hook in
kubespray,run_yamllint = truein community.general) and the Data profile has nowhere to report it; the Ansible
profile doc says "yamllint lints the YAML, which is the Data format's to ask for", but the Data format never asks. - evidence:
geerlingguy__ansible-role-docker/.github/workflows/ci.yml:32:run: pip3 install yamllint;:35-36:
run: |/yamllint .;.yamllint:1:extends: default;kubernetes-sigs__kubespray/.pre-commit-config.yaml:17-20:
- repo: https://github.com/adrienverge/yamllint.git...- id: yamllint;:31-34:
- repo: https://github.com/arhuman/ansible-static-lint...- id: astl. - repro: n/a (a gap)
- confidence: low (by design per docs/ecosystems/ansible.md; recorded because it is the ecosystem's universal tool)
Found by the regression-corpus audit (235 real repositories, one or more per ecosystem profile; corpus and expected results in corpus/). Evidence is quoted from the audited checkouts at the commits pinned in corpus/projects.toml; <checkouts>/<owner>__<repo> is such a checkout.
🤖 Generated with Claude Code
- 主要語言
- Python
- 星號
- 4
- 分支
- 1
- 平均合併
- 10 小時 41 分鐘
- 30 天內合併 PR
- 79
環境準備
這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
cpp-best-practices/project_validator 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 62/100
cpp-best-practices/project_validator#267 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
cpp-best-practices/project_validator#263 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 62/100
cpp-best-practices/project_validator#260 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 74/100
cpp-best-practices/project_validator#259 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 65/100
cpp-best-practices/project_validator#255 ·
維護者通常 1 天內回覆
查看 cpp-best-practices/project_validator 的全部 Issue
相似的 Issue
-
難度 1/5 1 小時以內 新手友好度 65/100
StevenBlack/hosts#3299 ·
-
`garak --report` overwrites the input report when its name has no ".report"可能已有人在做 @0z5a 今天認領。 未關閉needs-triage
難度 2/5 半天 新手友好度 72/100
維護者通常 2 天內回覆
-
plot_graph crashes when a mesh node has no m2m edge可能已有人在做 @tygvi 今天認領。 未關閉
難度 2/5 1-3 小時 新手友好度 78/100
mllam/neural-lam#883 · 1 則留言 ·
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 62/100
future-agi/future-agi#4092 · 1 則留言 ·
維護者通常 1 天內回覆
-
transcript analytics: a text whose only protected spans the prose pass redacts is withheld whole未關閉
難度 1/5 1 小時以內 新手友好度 82/100
WingedGuardian/GENesis-AGI#4641 ·
維護者通常 1 天內回覆