argoproj / argo-cd

Declarative Continuous Deployment for Kubernetes
https://argo-cd.readthedocs.io
Apache License 2.0
18.04k stars 5.51k forks source link

Unknown conversion error when syncing a Helm chart with v2.HPA #17795

Open suzaku opened 7 months ago

suzaku commented 7 months ago

Checklist:

Describe the bug

Get the following error when syncing a Helm chart:

ComparisonError: Failed to compare desired state to live state: failed to calculate diff: error calculating structured merge diff: error calculating diff: error while running updater.Apply: converting (v2.HorizontalPodAutoscaler) to (v1.HorizontalPodAutoscaler): unknown conversion

To Reproduce

Helm repo: https://istio-release.storage.googleapis.com/charts Chart: istiod Version: 1.16.7

This issue happened when I was migrating a Helm managed chart to ArgoCD, to emulate the situation:

  1. Use helm install directly
  2. Create an ArgoCD application for the same chart

Expected behavior

ArgoCD adopts the existing resources from Helm.

Screenshots

Version

v2.8.6

Logs

Paste any relevant application logs here.
patrickdappollonio commented 5 months ago

This might be related: https://github.com/argoproj/argo-cd/issues/11136#issuecomment-1486846835

sacherus commented 3 months ago

Try updating argocd version to the at least 2.10.

suzaku commented 3 months ago

Try updating argocd version to the at least 2.10.

In #11136 you said you were using 2.10.5 and it still had this issue, no?

andrii-korotkov-verkada commented 2 weeks ago

ArgoCD versions 2.10 and below have reached EOL. Can you upgrade and tell us if the issue is still present, please?