Closed ffjlabo closed 1 week ago
Attention: Patch coverage is 23.07692%
with 20 lines
in your changes missing coverage. Please review.
Project coverage is 25.26%. Comparing base (
6b43655
) to head (f1ef1a9
). Report is 2 commits behind head on master.
Files with missing lines | Patch % | Lines |
---|---|---|
pkg/app/piped/driftdetector/kubernetes/detector.go | 0.00% | 12 Missing :warning: |
pkg/git/gittest/git.mock.go | 0.00% | 8 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@Warashi Sorry, plz re-approve 🙏
What this PR does:
Fixed to execute
git clean -f
for every app dir after doing k8s drift detection.Why we need it:
During drift detection, a Git repository is cloned and reused, and a common manifest cache is utilized for various operations like drift detection, plan preview, plan, and deploy. If an incorrect manifest is cached, it can affect other processes. When running kustomize build --enable-helm, a charts directory is created, and the Helm chart is downloaded locally. However, before kustomize v5.3.0, this directory is not updated if the Helm chart version in kustomization.yaml changes, causing drift detection to load outdated manifests. These manifests are cached based on commit hash, leading to incorrect manifests being applied during Plan or Deploy if the same commit hash is used.
For the context, see https://github.com/pipe-cd/pipecd/issues/5124#issuecomment-2277628373
Which issue(s) this PR fixes:
Fixes #5124
Does this PR introduce a user-facing change?: