Skip to content

fix(argocd-apps): allow nullified top level item#3661

Merged
yu-croco merged 2 commits intoargoproj:mainfrom
fxbtr:fix/apps
Jan 12, 2026
Merged

fix(argocd-apps): allow nullified top level item#3661
yu-croco merged 2 commits intoargoproj:mainfrom
fxbtr:fix/apps

Conversation

@fxbtr
Copy link
Copy Markdown
Contributor

@fxbtr fxbtr commented Jan 8, 2026

Hi,

Let's say I have the following need, using Helmfile:

# default.values.yaml
applications:
  old-application:
    namespace: some-ns

# staging.values.yaml
# here I need old-application, same as default

# prod.values.yaml
# I no longer want old-application in this environment.
applications:
  old-application: null
  application:
    namespace: some-ns

That would make sense according to the helm documentation on deleting a default key.

But this was not doable in 2.0.3 due to

STDERR:
  coalesce.go:298: warning: cannot overwrite table with non table for argo.argocd-apps.applications.old-application (map[destination:map[namespace: server:https://kubernetes.default.svc] finalizers:[resources-finalizer.argocd.argoproj.io] namespace: project:applications source:map[directory:map[recurse:true] path: repoURL:... targetRevision:develop] syncPolicy:map[automated:map[prune:false selfHeal:false]]])
  coalesce.go:298: warning: cannot overwrite table with non table for argo.argocd-apps.applications.old-application (map[destination:map[namespace: server:https://kubernetes.default.svc] finalizers:[resources-finalizer.argocd.argoproj.io] namespace: project:applications source:map[directory:map[recurse:true] path: repoURL:... targetRevision:develop] syncPolicy:map[automated:map[prune:false selfHeal:false]]])
  Error: template: argo/charts/argocd-apps/templates/applications.yaml:6:19: executing "argo/charts/argocd-apps/templates/applications.yaml" at <$appData.additionalAnnotations>: nil pointer evaluating interface {}.additionalAnnotations
  Use --debug flag to render out invalid YAML

Signed-off-by: fxbtr

Checklist:

  • I have bumped the chart version according to versioning
  • I have updated the documentation according to documentation
  • I have updated the chart changelog with all the changes that come with this pull request according to changelog.
  • Any new values are backwards compatible and/or have sensible default.
  • I have signed off all my commits as required by DCO.
  • I have created a separate pull request for each chart according to pull requests
  • My build is green (troubleshooting builds).

Signed-off-by: fxbtr <fxbrottier@gmail.com>
Copy link
Copy Markdown
Member

@mkilchhofer mkilchhofer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for your contribution @fxbtr 🙏

@yu-croco yu-croco merged commit b698c54 into argoproj:main Jan 12, 2026
6 checks passed
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.

3 participants