Skip to content

feat: tidy preflight internal types#678

Merged
shanshanying merged 4 commits into
mainfrom
feature/tidy-preflight-internal-types
May 27, 2026
Merged

feat: tidy preflight internal types#678
shanshanying merged 4 commits into
mainfrom
feature/tidy-preflight-internal-types

Conversation

@shanshanying
Copy link
Copy Markdown
Contributor

@shanshanying shanshanying commented May 25, 2026

Keep KubeBlocks preflight on the native troubleshoot Preflight API and limit the default checks to cluster-side requirements: Kubernetes version, node count, and required VolumeSnapshot CRDs.

Remove host preflight loading and execution, provider-specific preflight YAMLs, and the KubeBlocks-specific extend analyzer/collector/type layers that were only used by the removed checks.

Update tests and fixtures for native Preflight-only parsing and execution.

@github-actions github-actions Bot added the size/XXL Denotes a PR that changes 1000+ lines. label May 25, 2026
@shanshanying shanshanying changed the title tidy preflight internal types feat: tidy preflight internal types May 25, 2026
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 26, 2026

Codecov Report

❌ Patch coverage is 47.76119% with 35 lines in your changes missing coverage. Please review.
✅ Project coverage is 39.93%. Comparing base (6cb99fc) to head (39e6501).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
pkg/preflight/interactive/interactive.go 0.00% 16 Missing ⚠️
pkg/cmd/kubeblocks/preflight.go 36.84% 11 Missing and 1 partial ⚠️
pkg/preflight/load_spec.go 66.66% 4 Missing and 2 partials ⚠️
pkg/preflight/analyze.go 50.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #678   +/-   ##
=======================================
  Coverage   39.93%   39.93%           
=======================================
  Files         172      172           
  Lines       24024    24024           
=======================================
  Hits         9595     9595           
  Misses      13308    13308           
  Partials     1121     1121           
Flag Coverage Δ
unittests 39.93% <47.76%> (ø)

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

☔ View full report in Codecov by Sentry.
📢 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.

@shanshanying shanshanying linked an issue May 26, 2026 that may be closed by this pull request
@shanshanying
Copy link
Copy Markdown
Contributor Author

/approve to trigger test

Keep KubeBlocks preflight on the native troubleshoot Preflight API and limit the default checks to cluster-side requirements: Kubernetes version, node count, and required VolumeSnapshot CRDs.

Remove host preflight loading and execution, provider-specific preflight YAMLs, and the KubeBlocks-specific extend analyzer/collector/type layers that were only used by the removed checks.

Update tests and fixtures for native Preflight-only parsing and execution. Do not upgrade github.com/replicatedhq/troubleshoot because v0.123.0 requires a newer Kubernetes dependency stack than this branch currently supports.
Pin github.com/cyphar/filepath-securejoin to v0.5.1 via replace. containers/storage v1.59.1 still imports the legacy OpenInRoot and Reopen wrappers from the root package, while v0.6.x removes those wrappers.

v0.5.1 keeps the legacy root-package wrappers and still provides pathrs-lite for opencontainers/selinux, which fixes the golangci-lint typecheck failure on Linux without changing the troubleshoot version.
@shanshanying shanshanying force-pushed the feature/tidy-preflight-internal-types branch from 368c0cd to 39e6501 Compare May 27, 2026 06:42
@shanshanying shanshanying merged commit f15a72b into main May 27, 2026
12 checks passed
@shanshanying shanshanying deleted the feature/tidy-preflight-internal-types branch May 27, 2026 06:59
@github-actions github-actions Bot added this to the Release 1.0 milestone May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XXL Denotes a PR that changes 1000+ lines.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Improvement] preflight api is deprecated

4 participants