🐛 (helm/v2-alpha): remove deprecated v1-alpha plugin entry from PROJECT file#5436
Conversation
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: camilamacedo86 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Pull request overview
This PR attempts to address issue #5434 by removing the deprecated helm.kubebuilder.io/v1-alpha plugin entry from the PROJECT file when scaffolding the helm/v2-alpha plugin. The intent is to prevent confusion from having both v1-alpha and v2-alpha entries coexisting in the PROJECT file.
Changes:
- Added a new
removeV1AlphaPluginEntry()method to safely remove the v1-alpha plugin entry from the config - Called this method from
PostScaffold()with the intention of cleaning up deprecated entries - Added comprehensive tests for the removal logic
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| pkg/plugins/optional/helm/v2alpha/edit.go | Added constant for v1-alpha plugin key, implemented removeV1AlphaPluginEntry() method, and integrated it into PostScaffold() |
| pkg/plugins/optional/helm/v2alpha/edit_test.go | Added unit tests for removeV1AlphaPluginEntry() and PostScaffold integration |
…ECT file When scaffolding helm/v2-alpha plugin, the deprecated helm.kubebuilder.io/v1-alpha entry now gets automatically removed from the PROJECT file during PostScaffold. This prevents confusion and clutter since v2-alpha is a complete replacement for v1-alpha and both entries should not coexist. The removal is safe and only happens if the v1-alpha entry exists, with graceful handling for projects that don't have it or use older config versions.
d3cade8 to
8061ce2
Compare
When scaffolding helm/v2-alpha plugin, the deprecated helm.kubebuilder.io/v1-alpha entry now gets automatically removed from the PROJECT file. This prevents confusion and clutter since v2-alpha is a complete replacement for v1-alpha and both entries should not coexist.
The removal is safe and only happens if the v1-alpha entry exists, with graceful handling for projects that don't have it or use older config versions.
Closes: #5434