Skip to content

Fix MISSING_PACKAGES array append in validate-cks-node (#14755) - #14944

Open
ravening wants to merge 1 commit into
apache:mainfrom
ravening:vibe/fix-14755-cks-missing-packages-96810d
Open

ravening wants to merge 1 commit into
apache:mainfrom
ravening:vibe/fix-14755-cks-missing-packages-96810d

Conversation

@ravening

@ravening ravening commented Dec 2, 2026

Copy link
Copy Markdown
Member

Description

On Debian/Ubuntu, validate-cks-node collected missing packages with MISSING_PACKAGES+="$package", which appends to the string in element 0 instead of adding an array element: the missing count was always 1 and names were concatenated (e.g. cloud-guest-utilsapt-transport-https...). Fixed to MISSING_PACKAGES+=("$package"), matching the RPM branch.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • Build/CI
  • Test (unit or integration test code)

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

How Has This Been Tested?

Ran the script with a stubbed dpkg (cloud-init and curl "installed"): before the fix it printed count 1 with concatenated names; after the fix it prints the correct count 12 with space-separated names and exit status 1. bash -n syntax check passes.

Closes #14755

### Description

On Debian/Ubuntu, `validate-cks-node` collected missing packages with `MISSING_PACKAGES+="$package"`, which appends to the string in element 0 instead of adding an array element: the missing count was always 1 and names were concatenated (e.g. `cloud-guest-utilsapt-transport-https...`). Fixed to `MISSING_PACKAGES+=("$package")`, matching the RPM branch.

### Types of changes

- [ ] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] New feature (non-breaking change which adds functionality)
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] Enhancement (improves an existing feature and functionality)
- [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
- [ ] Build/CI
- [ ] Test (unit or integration test code)

### Bug Severity

- [ ] BLOCKER
- [ ] Critical
- [ ] Major
- [x] Minor
- [ ] Trivial

### How Has This Been Tested?

Ran the script with a stubbed `dpkg` (cloud-init and curl "installed"): before the fix it printed count `1` with concatenated names; after the fix it prints the correct count `12` with space-separated names and exit status 1. `bash -n` syntax check passes.

Closes apache#14755

Co-authored-by: ravening <ravening@users.noreply.github.com>
@codecov

codecov Bot commented Dec 2, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 3.86%. Comparing base (8eaff97) to head (d92fafc).

Additional details and impacted files
@@          Coverage Diff           @@
##            main   #14944   +/-   ##
======================================
  Coverage   3.86%    3.86%           
======================================
  Files        494      494           
  Lines      42890    42890           
  Branches    8142     8142           
======================================
  Hits        1657     1657           
  Misses     41001    41001           
  Partials     232      232           
Flag Coverage Δ
uitests 3.86% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CKS: validate-cks-node merges missing package names into one string on Debian/Ubuntu

2 participants