CNTRLPLANE-3610: Decouple CAPI provider Go module dependencies#8704
CNTRLPLANE-3610: Decouple CAPI provider Go module dependencies#8704csrwng wants to merge 1 commit into
Conversation
|
Pipeline controller notification For optional jobs, comment This repository is configured in: LGTM mode |
|
@csrwng: This pull request references CNTRLPLANE-3610 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
Skipping CI for Draft Pull Request. |
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThis PR adds a stamp-file based CAPI sync workflow and tooling: a Go copier (hack/copy-capi-types) with tests, a provider sync script (hack/capi-sync-provider.sh), per-provider vendored module manifests under hack/capi-vendor/, Makefile targets to run/verify capi-sync and to generate CRDs from workspace modules, go.mod replace mappings to local pkg/capi modules, .gitignore and golangci settings updates, and a large set of new/updated Cluster API provider API type files under pkg/capi/* (AWS, Azure, Agent, GCP, IBMCloud, KubeVirt, OpenStack) plus related go.mod files. Sequence DiagramsequenceDiagram
participant DevMake as Makefile/update
participant SyncScript as hack/capi-sync-provider.sh
participant Copier as hack/copy-capi-types
participant Vendor as hack/capi-vendor/*
participant PkgCAPI as pkg/capi/*
participant ControllerGen as controller-gen
DevMake->>SyncScript: invoke capi-sync per provider
SyncScript->>Vendor: download upstream module (go mod download)
SyncScript->>Copier: run copier (--src upstream --dst pkg/capi/<provider>)
Copier->>PkgCAPI: write copied/stripped Go files
SyncScript->>ControllerGen: run controller-gen with workspace paths
ControllerGen->>PkgCAPI: generate CRDs
DevMake->>DevMake: touch ./pkg/capi/<provider>/.synced (stamp)
Suggested reviewers
✨ Finishing Touches🧪 Generate unit tests (beta)
|
|
/pipeline required |
|
Scheduling tests matching the |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: csrwng 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.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@hack/capi-vendor/openstack/go.mod`:
- Around line 5-55: Add the OSV query result for the newly pinned direct
dependency sigs.k8s.io/cluster-api-provider-openstack v0.13.3 to the PR notes:
run an osv.dev query (or use `govulncheck`/OSV API) for module
"sigs.k8s.io/cluster-api-provider-openstack" at version "v0.13.3", capture the
JSON response (which returned an empty object {}), and paste that output into
the PR description or changelog entry so the absence of vulnerabilities is
documented alongside the go.mod change.
In `@hack/copy-capi-types/main.go`:
- Around line 167-227: The cascade loop correctly gathers all functions to
remove into funcRemoveSet but stripDecls is still called with the original
crossFileRemove slice, so newly discovered removals are never stripped; change
the final call to stripDecls to pass the fully-expanded removal set by
converting funcRemoveSet into a slice of *ast.FuncDecl (and/or build a new
removal slice variable) and use that in place of crossFileRemove when calling
stripDecls; keep existing crossNames usage for the reason field.
In `@Makefile`:
- Around line 560-565: The .synced target only depends on
hack/capi-vendor/%/go.mod and CONTROLLER_GEN, so update the rule for
$(DIR)/pkg/capi/%/.synced to also depend on the sync script and any copy/vendor
helper inputs that affect generated output (e.g.
$(DIR)/hack/capi-sync-provider.sh and
$(DIR)/hack/capi-vendor/%/vendor_imports.go and/or the copy tool binary variable
used during sync). In practice add those filenames/variables to the prerequisite
list for the $(DIR)/pkg/capi/%/.synced target so changes to
hack/capi-sync-provider.sh, vendor_imports.go, or the copy tool will invalidate
the .synced stamp and force re-running the cd/tidy/sync sequence.
In `@pkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.go`:
- Around line 24-32: The Template field in
AzureASOManagedMachinePoolTemplateSpec is using the wrong resource type
(AzureASOManagedControlPlaneResource) causing machine-pool fields like
providerIDList to be omitted; update the Template field's type to
AzureASOManagedMachinePoolResource (i.e., change the struct field Template
AzureASOManagedControlPlaneResource to Template
AzureASOManagedMachinePoolResource) so the CRD uses the machine-pool schema, and
run codegen/CRD generation to regenerate manifests after the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 74050ac9-95dd-4433-a9ec-ccf6efc47fa4
⛔ Files ignored due to path filters (128)
go.sumis excluded by!**/*.sumhack/capi-vendor/agent/go.sumis excluded by!**/*.sumhack/capi-vendor/aws/go.sumis excluded by!**/*.sumhack/capi-vendor/azure/go.sumis excluded by!**/*.sumhack/capi-vendor/gcp/go.sumis excluded by!**/*.sumhack/capi-vendor/ibmcloud/go.sumis excluded by!**/*.sumhack/capi-vendor/kubevirt/go.sumis excluded by!**/*.sumhack/capi-vendor/openstack/go.sumis excluded by!**/*.sumhack/workspace/go.workis excluded by!**/*.workpkg/capi/agent/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/agent/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/exp/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/exp/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/azure/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/gcp/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/ibmcloud/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/ibmcloud/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/kubevirt/api/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/openstack/api/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/openstack/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/CHANGELOG.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/LICENSE.txtis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/README.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/assets.jsonis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/autorest.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/availabilitysets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/build.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/capacityreservationgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/capacityreservations_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/ci.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/client_factory.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceoperatingsystems_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceroleinstances_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceroles_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudservices_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudservicesupdatedomain_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/constants.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/dedicatedhostgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/dedicatedhosts_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskaccesses_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskencryptionsets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskrestorepoint_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/disks_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryapplications_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryapplicationversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/gallerysharingprofile_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/images_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/loganalytics_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/models.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/models_serde.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/operations_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/options.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/proximityplacementgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/resourceskus_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/responses.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/restorepointcollections_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/restorepoints_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/snapshots_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sshpublickeys_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/time_rfc3339.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/usage_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineextensionimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineimagesedgezone_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineruncommands_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachines_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetrollingupgrades_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvmextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvmruncommands_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvms_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinesizes_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/.gitignoreis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/.travis.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/CODE_OF_CONDUCT.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/CONTRIBUTING.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/LICENSEis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/README.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/arrays.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/converter.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/doc.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/error.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/numerics.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/patterns.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/types.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/utils.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/validator.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/wercker.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/CHANGELOG.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/LICENSE.txtis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateAccessPolicy.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateEncryptionConfig.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateIdentityProviderConfig.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateCapability.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateEksAnywhereSubscription.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateFargateProfile.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateNodegroup.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreatePodIdentityAssociation.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteCapability.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteEksAnywhereSubscription.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteFargateProfile.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteNodegroup.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeletePodIdentityAssociation.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeregisterCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAddonConfiguration.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAddonVersions.gois excluded by!vendor/**,!**/vendor/**
📒 Files selected for processing (172)
.gitignore.golangci.ymlMakefilego.modhack/capi-sync-provider.shhack/capi-vendor/agent/go.modhack/capi-vendor/agent/vendor_imports.gohack/capi-vendor/aws/go.modhack/capi-vendor/aws/vendor_imports.gohack/capi-vendor/azure/go.modhack/capi-vendor/azure/vendor_imports.gohack/capi-vendor/gcp/go.modhack/capi-vendor/gcp/vendor_imports.gohack/capi-vendor/ibmcloud/go.modhack/capi-vendor/ibmcloud/vendor_imports.gohack/capi-vendor/kubevirt/go.modhack/capi-vendor/kubevirt/vendor_imports.gohack/capi-vendor/openstack/go.modhack/capi-vendor/openstack/vendor_imports.gohack/copy-capi-types/main.gopkg/capi/agent/go.modpkg/capi/agent/v1alpha1/agentcluster_types.gopkg/capi/agent/v1alpha1/agentmachine_types.gopkg/capi/agent/v1alpha1/agentmachinetemplate_types.gopkg/capi/agent/v1alpha1/groupversion_info.gopkg/capi/agent/v1alpha1/types.gopkg/capi/agent/v1beta1/agentcluster_types.gopkg/capi/agent/v1beta1/agentmachine_types.gopkg/capi/agent/v1beta1/agentmachinetemplate_types.gopkg/capi/agent/v1beta1/groupversion_info.gopkg/capi/agent/v1beta1/types.gopkg/capi/aws/api/v1beta1/awscluster_types.gopkg/capi/aws/api/v1beta1/awsclustertemplate_types.gopkg/capi/aws/api/v1beta1/awsidentity_types.gopkg/capi/aws/api/v1beta1/awsmachine_types.gopkg/capi/aws/api/v1beta1/awsmachinetemplate_types.gopkg/capi/aws/api/v1beta1/bastion.gopkg/capi/aws/api/v1beta1/conditions_consts.gopkg/capi/aws/api/v1beta1/doc.gopkg/capi/aws/api/v1beta1/groupversion_info.gopkg/capi/aws/api/v1beta1/network_types.gopkg/capi/aws/api/v1beta1/s3bucket.gopkg/capi/aws/api/v1beta1/tags.gopkg/capi/aws/api/v1beta1/types.gopkg/capi/aws/api/v1beta2/awscluster_types.gopkg/capi/aws/api/v1beta2/awsclustertemplate_types.gopkg/capi/aws/api/v1beta2/awsidentity_types.gopkg/capi/aws/api/v1beta2/awsmachine_types.gopkg/capi/aws/api/v1beta2/awsmachinetemplate_types.gopkg/capi/aws/api/v1beta2/bastion.gopkg/capi/aws/api/v1beta2/conditions_consts.gopkg/capi/aws/api/v1beta2/defaults.gopkg/capi/aws/api/v1beta2/doc.gopkg/capi/aws/api/v1beta2/groupversion_info.gopkg/capi/aws/api/v1beta2/network_types.gopkg/capi/aws/api/v1beta2/s3bucket.gopkg/capi/aws/api/v1beta2/tags.gopkg/capi/aws/api/v1beta2/types.gopkg/capi/aws/api/v1beta2/webhooks.gopkg/capi/aws/exp/api/v1beta1/awsmachinepool_types.gopkg/capi/aws/exp/api/v1beta1/conditions_consts.gopkg/capi/aws/exp/api/v1beta1/doc.gopkg/capi/aws/exp/api/v1beta1/finalizers.gopkg/capi/aws/exp/api/v1beta1/groupversion_info.gopkg/capi/aws/exp/api/v1beta1/types.gopkg/capi/aws/exp/api/v1beta2/awsmachinepool_types.gopkg/capi/aws/exp/api/v1beta2/conditions_consts.gopkg/capi/aws/exp/api/v1beta2/doc.gopkg/capi/aws/exp/api/v1beta2/finalizers.gopkg/capi/aws/exp/api/v1beta2/groupversion_info.gopkg/capi/aws/exp/api/v1beta2/types.gopkg/capi/aws/exp/api/v1beta2/validation.gopkg/capi/aws/go.modpkg/capi/azure/api/v1beta1/azureasomanagedcluster_types.gopkg/capi/azure/api/v1beta1/azureasomanagedclustertemplate_types.gopkg/capi/azure/api/v1beta1/azureasomanagedcontrolplane_types.gopkg/capi/azure/api/v1beta1/azureasomanagedcontrolplanetemplate_types.gopkg/capi/azure/api/v1beta1/azureasomanagedmachinepool_types.gopkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.gopkg/capi/azure/api/v1beta1/azurecluster_default.gopkg/capi/azure/api/v1beta1/azurecluster_types.gopkg/capi/azure/api/v1beta1/azurecluster_validation.gopkg/capi/azure/api/v1beta1/azureclusteridentity_types.gopkg/capi/azure/api/v1beta1/azureclustertemplate_default.gopkg/capi/azure/api/v1beta1/azureclustertemplate_types.gopkg/capi/azure/api/v1beta1/azureclustertemplate_validation.gopkg/capi/azure/api/v1beta1/azureimage_validation.gopkg/capi/azure/api/v1beta1/azuremachine_default.gopkg/capi/azure/api/v1beta1/azuremachine_types.gopkg/capi/azure/api/v1beta1/azuremachine_validation.gopkg/capi/azure/api/v1beta1/azuremachinetemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedcluster_types.gopkg/capi/azure/api/v1beta1/azuremanagedclustertemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_default.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_types.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_default.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedmachinepool_types.gopkg/capi/azure/api/v1beta1/azuremanagedmachinepooltemplate_types.gopkg/capi/azure/api/v1beta1/consts.gopkg/capi/azure/api/v1beta1/doc.gopkg/capi/azure/api/v1beta1/groupversion_info.gopkg/capi/azure/api/v1beta1/tags.gopkg/capi/azure/api/v1beta1/types.gopkg/capi/azure/api/v1beta1/types_class.gopkg/capi/azure/api/v1beta1/types_template.gopkg/capi/azure/go.modpkg/capi/gcp/api/v1beta1/doc.gopkg/capi/gcp/api/v1beta1/endpoints.gopkg/capi/gcp/api/v1beta1/gcpcluster_types.gopkg/capi/gcp/api/v1beta1/gcpclustertemplate_types.gopkg/capi/gcp/api/v1beta1/gcpmachine_types.gopkg/capi/gcp/api/v1beta1/gcpmachinetemplate_types.gopkg/capi/gcp/api/v1beta1/groupversion_info.gopkg/capi/gcp/api/v1beta1/labels.gopkg/capi/gcp/api/v1beta1/tags.gopkg/capi/gcp/api/v1beta1/types.gopkg/capi/gcp/go.modpkg/capi/ibmcloud/api/v1beta1/conditions_consts.gopkg/capi/ibmcloud/api/v1beta1/doc.gopkg/capi/ibmcloud/api/v1beta1/groupversion_info.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervscluster_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsimage_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsmachine_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpccluster_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpcmachine_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpcmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta1/types.gopkg/capi/ibmcloud/api/v1beta2/conditions_consts.gopkg/capi/ibmcloud/api/v1beta2/doc.gopkg/capi/ibmcloud/api/v1beta2/groupversion_info.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervscluster_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsimage_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsmachine_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpccluster_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcmachine_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta2/types.gopkg/capi/ibmcloud/go.modpkg/capi/kubevirt/api/v1alpha1/condition_consts.gopkg/capi/kubevirt/api/v1alpha1/doc.gopkg/capi/kubevirt/api/v1alpha1/groupversion_info.gopkg/capi/kubevirt/api/v1alpha1/kubevirtcluster_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtclustertemplate_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtmachine_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtmachinetemplate_types.gopkg/capi/kubevirt/go.modpkg/capi/openstack/api/v1alpha1/conditions_consts.gopkg/capi/openstack/api/v1alpha1/doc.gopkg/capi/openstack/api/v1alpha1/groupversion_info.gopkg/capi/openstack/api/v1alpha1/openstackfloatingippool_types.gopkg/capi/openstack/api/v1alpha1/openstackserver_types.gopkg/capi/openstack/api/v1alpha1/types.gopkg/capi/openstack/api/v1beta1/conditions_consts.gopkg/capi/openstack/api/v1beta1/doc.gopkg/capi/openstack/api/v1beta1/groupversion_info.gopkg/capi/openstack/api/v1beta1/identity_types.gopkg/capi/openstack/api/v1beta1/openstackcluster_types.gopkg/capi/openstack/api/v1beta1/openstackclustertemplate_types.gopkg/capi/openstack/api/v1beta1/openstackmachine_types.gopkg/capi/openstack/api/v1beta1/openstackmachinetemplate_types.gopkg/capi/openstack/api/v1beta1/types.gopkg/capi/openstack/go.modpkg/capi/openstack/pkg/utils/errors/errors.gopkg/capi/openstack/pkg/utils/errors/terminal.gopkg/capi/openstack/pkg/utils/optional/types.gosupport/api/capi_types.go
💤 Files with no reviewable changes (2)
- pkg/capi/aws/api/v1beta1/tags.go
- pkg/capi/aws/api/v1beta1/network_types.go
| // AzureASOManagedMachinePoolTemplateSpec defines the desired state of AzureASOManagedMachinePoolTemplate. | ||
| type AzureASOManagedMachinePoolTemplateSpec struct { | ||
| Template AzureASOManagedControlPlaneResource `json:"template"` | ||
| } | ||
|
|
||
| // AzureASOManagedMachinePoolResource defines the templated resource. | ||
| type AzureASOManagedMachinePoolResource struct { | ||
| Spec AzureASOManagedMachinePoolTemplateResourceSpec `json:"spec,omitempty"` | ||
| } |
There was a problem hiding this comment.
Use the machine-pool resource type in the template spec.
Line 26 currently references AzureASOManagedControlPlaneResource, which gives this CRD the wrong template schema and drops machine-pool-specific fields like providerIDList.
Suggested fix
type AzureASOManagedMachinePoolTemplateSpec struct {
- Template AzureASOManagedControlPlaneResource `json:"template"`
+ Template AzureASOManagedMachinePoolResource `json:"template"`
}📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| // AzureASOManagedMachinePoolTemplateSpec defines the desired state of AzureASOManagedMachinePoolTemplate. | |
| type AzureASOManagedMachinePoolTemplateSpec struct { | |
| Template AzureASOManagedControlPlaneResource `json:"template"` | |
| } | |
| // AzureASOManagedMachinePoolResource defines the templated resource. | |
| type AzureASOManagedMachinePoolResource struct { | |
| Spec AzureASOManagedMachinePoolTemplateResourceSpec `json:"spec,omitempty"` | |
| } | |
| // AzureASOManagedMachinePoolTemplateSpec defines the desired state of AzureASOManagedMachinePoolTemplate. | |
| type AzureASOManagedMachinePoolTemplateSpec struct { | |
| Template AzureASOManagedMachinePoolResource `json:"template"` | |
| } | |
| // AzureASOManagedMachinePoolResource defines the templated resource. | |
| type AzureASOManagedMachinePoolResource struct { | |
| Spec AzureASOManagedMachinePoolTemplateResourceSpec `json:"spec,omitempty"` | |
| } |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@pkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.go`
around lines 24 - 32, The Template field in
AzureASOManagedMachinePoolTemplateSpec is using the wrong resource type
(AzureASOManagedControlPlaneResource) causing machine-pool fields like
providerIDList to be omitted; update the Template field's type to
AzureASOManagedMachinePoolResource (i.e., change the struct field Template
AzureASOManagedControlPlaneResource to Template
AzureASOManagedMachinePoolResource) so the CRD uses the machine-pool schema, and
run codegen/CRD generation to regenerate manifests after the change.
There was a problem hiding this comment.
This is a false positive — the upstream CAPZ source at sigs.k8s.io/cluster-api-provider-azure uses AzureASOManagedControlPlaneResource in the AzureASOManagedMachinePoolTemplateSpec.Template field as well. Our copy matches upstream exactly. This appears to be an intentional design choice in CAPZ where the control plane and machine pool templates share the same resource wrapper type (both contain only an embedded Resources []runtime.RawExtension field).
There was a problem hiding this comment.
@csrwng, thanks for the clarification. You're right — I was incorrect. The upstream CAPZ intentionally reuses AzureASOManagedControlPlaneResource for the AzureASOManagedMachinePoolTemplateSpec.Template field because both the control-plane and machine-pool ASO-managed template types share the same resource wrapper (containing only Resources []runtime.RawExtension). I'll record this so it isn't flagged in future reviews.
✏️ Learnings added
Learnt from: csrwng
Repo: openshift/hypershift PR: 8704
File: pkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.go:24-32
Timestamp: 2026-06-09T16:43:40.208Z
Learning: In the openshift/hypershift repo, `pkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.go` intentionally uses `AzureASOManagedControlPlaneResource` (not `AzureASOManagedMachinePoolResource`) as the type for `AzureASOManagedMachinePoolTemplateSpec.Template`. This matches the upstream CAPZ source (`sigs.k8s.io/cluster-api-provider-azure`) exactly: both the ASO-managed control-plane and machine-pool template specs share the same `AzureASOManagedControlPlaneResource` wrapper because it only contains `Resources []runtime.RawExtension`. Do not flag this as a type mismatch during code review.
Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.
🧠 Learnings used
Learnt from: csrwng
Repo: openshift/hypershift PR: 8697
File: pkg/capi/azure/api/v1beta1/azureclustertemplate_default.go:32-34
Timestamp: 2026-06-09T14:40:20.373Z
Learning: In the HyperShift repo, the Go packages under `pkg/capi/<provider>/` (copied from upstream via `hack/capi-sync-provider.sh`) are used only for CRD generation (e.g., by `controller-gen`) and as controller type references. Treat defaulting/validation/webhook logic in these copied files as intentionally dead code (e.g., functions like `setNodeOutboundLBDefaults`, `setBastionTemplateDefaults` are not invoked at runtime in HyperShift). During code review, do not raise actionable bug findings about runtime-safety issues in these copied files (such as missing nil-guards) based on theoretical reachability; only flag issues that would affect compilation/CRD generation (or that are clearly proven to be reachable in HyperShift runtime code).
Learnt from: csrwng
Repo: openshift/hypershift PR: 8697
File: pkg/capi/azure/api/v1beta1/azurecluster_validation.go:68-73
Timestamp: 2026-06-09T14:40:21.560Z
Learning: In openshift/hypershift, the packages under `pkg/capi/<provider>/` are intentionally “stripped” copies of upstream Cluster API provider types. They exist only for CRD generation and type references—NOT for running upstream webhook or validation logic. During code review of files in this directory tree, treat the absence of upstream webhook/validation entrypoints (e.g., `ValidateCreate`, `ValidateUpdate`, `ValidateDelete`, `SetupWebhookWithManager`) and validation helpers (e.g., `validateCluster`, `validateClusterSpec`, `validateNetworkSpec`, `validatePrivateDNSZoneName`) as expected. Do not request adding webhook/validation logic here; ensure any changes keep the stripped nature intact and avoid introducing the banned imports that the copy tool (`hack/copy-capi-types/main.go`) is designed to remove.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8704 +/- ##
=======================================
Coverage 41.54% 41.54%
=======================================
Files 758 758
Lines 93838 93838
=======================================
Hits 38986 38986
Misses 52107 52107
Partials 2745 2745
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
/pipeline required |
|
Scheduling tests matching the |
bryan-cox
left a comment
There was a problem hiding this comment.
Overall this is excellent work — decoupling K8s bumps from CAPI provider releases is a significant operational improvement.
Two items I'd like addressed before merge (the GenDecl cascade gap in Pass 2 and broadening callsAny); the rest are suggestions and nits.
No tests for the 750-line AST tool is a concern I'd like discussed — even a small TestProcessFile with testdata/ fixtures would dramatically reduce regression risk.
| } | ||
|
|
||
| var crossFileRemove []*ast.FuncDecl | ||
| var crossNames []string |
There was a problem hiding this comment.
[blocking] Cross-file cascade only handles FuncDecl, not GenDecl
Pass 2 iterates file.Decls but only checks *ast.FuncDecl. If a type in file A embeds or references a type stripped from file B, this cascade won't detect it — the within-file Pass 1 handles both FuncDecl and GenDecl via genDeclReferencesAny, but that logic wasn't carried to Pass 2.
This is a latent bug that will surface when an upstream provider reorganizes types across files. Fix: extend this loop to also check *ast.GenDecl with genDeclReferencesAny(gd, allStrippedSymbols).
There was a problem hiding this comment.
Good catch — fixed. Pass 2 now handles both *ast.FuncDecl and *ast.GenDecl, using genDeclReferencesAny for the latter. The cascade loop also uses collectStrippedSymbols (same as Pass 1) to track both function and type/var/const names.
| } | ||
|
|
||
| // callsAny checks if a function body calls any of the named symbols. | ||
| func callsAny(fn *ast.FuncDecl, symbols map[string]bool) bool { |
There was a problem hiding this comment.
[suggestion] callsAny only checks ast.CallExpr, missing other reference patterns
A function body can reference a stripped symbol via composite literals (strippedType{}), type assertions (x.(strippedType)), type conversions (strippedType(x)), or variable declarations (var x strippedType). These appear as ast.Ident nodes, not ast.CallExpr.
genDeclReferencesAny already does the right thing — it checks all ast.Ident nodes. Consider renaming this to referencesAny and broadening the check to match.
There was a problem hiding this comment.
Good point — renamed to referencesAny and broadened to check all ast.Ident nodes (matching genDeclReferencesAny's approach). This now catches composite literals, type assertions, type conversions, and variable declarations referencing stripped symbols.
| } | ||
|
|
||
| // stripDecls removes specified declarations and cleans up unused imports. | ||
| func stripDecls(fset *token.FileSet, file *ast.File, funcsToRemove []*ast.FuncDecl, genDeclsToRemove []*ast.GenDecl, _ map[string]bool) []byte { |
There was a problem hiding this comment.
nit: The last parameter is named _ and unused. Both call sites pass bannedAliases or nil. Remove the parameter to avoid confusion.
There was a problem hiding this comment.
Fixed — removed the unused parameter from stripDecls.
| dst := flag.String("dst", "", "destination directory for copied types") | ||
| var extraAllowed stringSlice | ||
| flag.Var(&extraAllowed, "allow", "additional allowed import prefix (can be repeated)") | ||
| var rewriteRules stringSlice |
There was a problem hiding this comment.
nit: --rewrite flag is implemented but the sync script never passes it. If this is for future use, a code comment explaining the intended use case would help. If it's dead code from prototyping, consider removing it.
There was a problem hiding this comment.
Removed — it was leftover from prototyping when imports were being rewritten to local paths. The replace directive approach made it unnecessary.
| # Download a module into the cache and print its directory. | ||
| mod_cache_dir() { | ||
| local module="$1" | ||
| (cd "$MOD_DIR" && GO111MODULE=on GOWORK=off GOFLAGS= go mod download -json "$module") | \ |
There was a problem hiding this comment.
[suggestion] mod_cache_dir uses fragile sed parsing
Parsing JSON with sed is brittle if the format changes. Consider jq:
mod_cache_dir() {
local module="$1"
(cd "$MOD_DIR" && GO111MODULE=on GOWORK=off GOFLAGS= go mod download -json "$module") | jq -r '.Dir'
}There was a problem hiding this comment.
Done — switched to jq -r '.Dir'.
| - linters: | ||
| - gocyclo | ||
| - unparam | ||
| path: 'hack/' |
There was a problem hiding this comment.
nit: This suppresses gocyclo and unparam for the entire hack/ directory. Consider narrowing to hack/copy-capi-types/ to avoid accidentally suppressing useful warnings in other hack scripts.
There was a problem hiding this comment.
Fixed — narrowed to hack/copy-capi-types/.
| cd $(DIR)/hack/capi-vendor/$$p && $(GO) mod tidy && $(GO) mod download; \ | ||
| done | ||
|
|
||
| .PHONY: capi-sync |
There was a problem hiding this comment.
[suggestion] Consider a verify-capi-sync target
The stamp-based approach relies on verify-git-clean to catch drift, but the error message will be opaque ("uncommitted changes in pkg/capi/"). A dedicated target that runs the sync and checks for diffs would give clear, actionable errors in CI.
There was a problem hiding this comment.
Added a verify-capi-sync target that runs the sync from scratch and checks for diffs in pkg/capi/. It's included in verify-parallel so it runs as part of make verify. Error message tells the developer exactly what to do:
ERROR: pkg/capi/ is out of sync with hack/capi-vendor/. Run 'make capi-sync-force' and commit the result.
| @@ -0,0 +1,111 @@ | |||
| #!/usr/bin/env bash | |||
There was a problem hiding this comment.
[suggestion] Document the end-to-end update workflow
The old "bump go.mod and run make update" no longer works for CAPI providers. Consider adding a header comment (or a README alongside) documenting the steps:
- Update
hack/capi-vendor/<provider>/go.modto the new version - Run
make capi-sync-force(ormake update) - Verify CRDs regenerated correctly
- Run
make depsto re-vendor
There was a problem hiding this comment.
Added a header comment to the sync script documenting the update steps:
- Edit
hack/capi-vendor/<provider>/go.modto the new version - Run
make capi-sync-force - Verify CRDs:
make generate - Re-vendor:
make deps - Run tests:
make test
AI Test Failure AnalysisJob: Generated by hypershift-analyze-e2e-failure post-step using Claude claude-opus-4-6 |
Test Resultse2e-aws
e2e-aks
|
AI Test Failure AnalysisJob: Generated by hypershift-analyze-e2e-failure post-step using Claude claude-opus-4-6 |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
hack/copy-capi-types/main.go (1)
494-513:⚠️ Potential issue | 🟠 MajorInclude receiver/parameter/result types in
referencesAnyfor cascade stripping
referencesAnyonly inspectsfn.Body, so cascade stripping can miss stripped symbols referenced solely infn.Recv, parameter types, or result types, leaving invalid generated code.Suggested fix
func referencesAny(fn *ast.FuncDecl, symbols map[string]bool) bool { - if fn.Body == nil { - return false - } - found := false - ast.Inspect(fn.Body, func(n ast.Node) bool { - if found { - return false - } - ident, ok := n.(*ast.Ident) - if ok && symbols[ident.Name] { - found = true - } - return true - }) - return found + check := func(n ast.Node) bool { + found := false + ast.Inspect(n, func(node ast.Node) bool { + if found { + return false + } + ident, ok := node.(*ast.Ident) + if ok && symbols[ident.Name] { + found = true + } + return true + }) + return found + } + + if fn.Recv != nil { + for _, f := range fn.Recv.List { + if check(f.Type) { + return true + } + } + } + if fn.Type.Params != nil { + for _, f := range fn.Type.Params.List { + if check(f.Type) { + return true + } + } + } + if fn.Type.Results != nil { + for _, f := range fn.Type.Results.List { + if check(f.Type) { + return true + } + } + } + return fn.Body != nil && check(fn.Body) }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@hack/copy-capi-types/main.go` around lines 494 - 513, The function referencesAny currently only inspects fn.Body and therefore misses identifiers referenced in the method receiver, parameter types, and result types; update referencesAny to also inspect fn.Recv, fn.Type.Params and fn.Type.Results (visit their *ast.FieldList nodes) and search for *ast.Ident the same way you do for the body so that any identifier used in receiver or signature types sets found=true; reuse the same ast.Inspect logic (or factor out an inspectNode helper) to walk those AST nodes (fn.Recv, fn.Type.Params, fn.Type.Results) in addition to fn.Body to ensure cascade stripping catches symbols referenced in signatures.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In `@hack/copy-capi-types/main.go`:
- Around line 494-513: The function referencesAny currently only inspects
fn.Body and therefore misses identifiers referenced in the method receiver,
parameter types, and result types; update referencesAny to also inspect fn.Recv,
fn.Type.Params and fn.Type.Results (visit their *ast.FieldList nodes) and search
for *ast.Ident the same way you do for the body so that any identifier used in
receiver or signature types sets found=true; reuse the same ast.Inspect logic
(or factor out an inspectNode helper) to walk those AST nodes (fn.Recv,
fn.Type.Params, fn.Type.Results) in addition to fn.Body to ensure cascade
stripping catches symbols referenced in signatures.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 0db6d833-6d48-4995-9e2e-c3ea1e482c95
📒 Files selected for processing (4)
.golangci.ymlMakefilehack/capi-sync-provider.shhack/copy-capi-types/main.go
✅ Files skipped from review due to trivial changes (1)
- .golangci.yml
c7eb668 to
af5fced
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
hack/copy-capi-types/main_test.go (1)
184-208: 💤 Low valueTest helper constructs a synthetic FuncDecl for interface methods, but this may not accurately test
referencesAny.For the "no body" test case (line 149-154), the code constructs a synthetic
FuncDeclfrom interface method signatures. However,referencesAnyreturnsfalsewhenfn.Body == nil(line 504), so the test correctly passes. The synthetic construction is unnecessarily complex.Simplified approach
The test could be simplified to just parse a function declaration without a body (e.g., an external function declaration):
{ name: "When a function has no body, it should return false", src: `package p func External()`, // no body symbols: map[string]bool{"Bar": true}, want: false, },🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@hack/copy-capi-types/main_test.go` around lines 184 - 208, The test helper builds a synthetic *ast.FuncDecl from interface methods which is unnecessary because referencesAny(fn) already returns false when fn.Body == nil; instead simplify the test by creating/using a parsed FuncDecl with no body (i.e., a real function declaration lacking a body) rather than constructing one from interface types. Locate the test that creates fn from file.Decls and replace that path with a simpler case that parses "func External()" (or equivalent) so the resulting *ast.FuncDecl has nil Body and the test exercises referencesAny directly.hack/capi-sync-provider.sh (1)
25-27: 💤 Low value
run_gois defined but never called.The
run_go()helper function sets proper Go environment variables but is only used insidecopy_types(). Themod_cache_dir()function at line 32 duplicates the environment setup inline instead of usingrun_go.Suggested consistency improvement
mod_cache_dir() { local module="$1" - (cd "$MOD_DIR" && GO111MODULE=on GOWORK=off GOFLAGS= go mod download -json "$module") | jq -r '.Dir' + (cd "$MOD_DIR" && GO111MODULE=on GOWORK=off GOFLAGS= run_go mod download -json "$module") | jq -r '.Dir' }Note: This would require
run_goto be available in the subshell context or the function body to be restructured.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@hack/capi-sync-provider.sh` around lines 25 - 27, The helper run_go() is defined but not used in mod_cache_dir(), which duplicates its Go env setup; update mod_cache_dir() to call run_go instead of inlining GO111MODULE/GOWORK/GOFLAGS so the environment is centralized (either call run_go in the same shell or export the function into the subshell with export -f run_go before using it), and remove the duplicated env variables in mod_cache_dir() so copy_types(), mod_cache_dir(), and any other callers all use run_go() consistently.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@hack/copy-capi-types/main.go`:
- Around line 339-341: The parse error is currently swallowed by the `if err !=
nil { continue }` check; instead, log the failure so it’s visible for debugging.
Replace the silent `continue` in the parsing loop with a call to the project
logger (or fmt/stderr) that records the filename/identifier being parsed and the
`err` value (include any position info if available), then decide to continue or
abort as appropriate; look for the parsing call that produces `err` and update
that branch to emit a clear error message referencing the file being parsed and
`err`.
---
Nitpick comments:
In `@hack/capi-sync-provider.sh`:
- Around line 25-27: The helper run_go() is defined but not used in
mod_cache_dir(), which duplicates its Go env setup; update mod_cache_dir() to
call run_go instead of inlining GO111MODULE/GOWORK/GOFLAGS so the environment is
centralized (either call run_go in the same shell or export the function into
the subshell with export -f run_go before using it), and remove the duplicated
env variables in mod_cache_dir() so copy_types(), mod_cache_dir(), and any other
callers all use run_go() consistently.
In `@hack/copy-capi-types/main_test.go`:
- Around line 184-208: The test helper builds a synthetic *ast.FuncDecl from
interface methods which is unnecessary because referencesAny(fn) already returns
false when fn.Body == nil; instead simplify the test by creating/using a parsed
FuncDecl with no body (i.e., a real function declaration lacking a body) rather
than constructing one from interface types. Locate the test that creates fn from
file.Decls and replace that path with a simpler case that parses "func
External()" (or equivalent) so the resulting *ast.FuncDecl has nil Body and the
test exercises referencesAny directly.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 10ea9f40-42c0-417a-9c6c-f20e0789f642
📒 Files selected for processing (5)
.golangci.ymlMakefilehack/capi-sync-provider.shhack/copy-capi-types/main.gohack/copy-capi-types/main_test.go
✅ Files skipped from review due to trivial changes (1)
- .golangci.yml
There was a problem hiding this comment.
♻️ Duplicate comments (1)
hack/copy-capi-types/main.go (1)
338-341:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winParse errors in cross-file cascade are silently ignored.
If re-parsing a file fails, the error is swallowed with
continue. This could mask corruption introduced during Pass 1 stripping, making debugging difficult.Suggested fix: log the parse failure
file, err := parser.ParseFile(fset, r.base, content, parser.ParseComments) if err != nil { + log.Printf("warning: failed to re-parse %s in cross-file cascade: %v", r.base, err) continue }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@hack/copy-capi-types/main.go` around lines 338 - 341, The loop silently continues when parser.ParseFile(fset, r.base, content, parser.ParseComments) returns an error, which hides parse failures; update the handler for parser.ParseFile in main.go to log the failure with context (include r.base and the parse error) instead of silently continuing—use the existing logger or fmt/log to emit a clear message referencing parser.ParseFile, fset, r.base and err, and consider failing fast (returning the error) if a parse error indicates corruption from Pass 1 rather than merely continuing.
🧹 Nitpick comments (1)
hack/capi-sync-provider.sh (1)
105-123: 💤 Low value
upstream_modulesilently returns empty for unknown providers.If
upstream_moduleis called with an unrecognized provider (e.g., due to a typo or adding a new provider without updating this function),MODULE_PATHwill be empty, causingcontroller-gento fail with a confusing error. The maincasestatement already exits on unknown providers, so this is unlikely, but adding a fallback improves debuggability.Suggested fix
upstream_module() { case "$1" in agent) echo "github.com/openshift/cluster-api-provider-agent/api" ;; aws) echo "sigs.k8s.io/cluster-api-provider-aws/v2" ;; azure) echo "sigs.k8s.io/cluster-api-provider-azure" ;; gcp) echo "sigs.k8s.io/cluster-api-provider-gcp" ;; ibmcloud) echo "sigs.k8s.io/cluster-api-provider-ibmcloud" ;; kubevirt) echo "sigs.k8s.io/cluster-api-provider-kubevirt" ;; openstack) echo "sigs.k8s.io/cluster-api-provider-openstack" ;; + *) echo "ERROR: upstream_module: unknown provider: $1" >&2; exit 1 ;; esac }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@hack/capi-sync-provider.sh` around lines 105 - 123, upstream_module currently returns empty for unknown providers, which leads to a confusing failure when MODULE_PATH is blank; update the upstream_module function to include a default (*) branch that prints a clear error to stderr (including the bad provider value from "$1") and exits non‑zero, and additionally guard the MODULE_PATH usage before invoking controller-gen (check that MODULE_PATH is non-empty and, if not, print an explanatory error and exit) so the script fails fast with a helpful message; refer to upstream_module and MODULE_PATH/controller-gen invocation for where to make these changes.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Duplicate comments:
In `@hack/copy-capi-types/main.go`:
- Around line 338-341: The loop silently continues when parser.ParseFile(fset,
r.base, content, parser.ParseComments) returns an error, which hides parse
failures; update the handler for parser.ParseFile in main.go to log the failure
with context (include r.base and the parse error) instead of silently
continuing—use the existing logger or fmt/log to emit a clear message
referencing parser.ParseFile, fset, r.base and err, and consider failing fast
(returning the error) if a parse error indicates corruption from Pass 1 rather
than merely continuing.
---
Nitpick comments:
In `@hack/capi-sync-provider.sh`:
- Around line 105-123: upstream_module currently returns empty for unknown
providers, which leads to a confusing failure when MODULE_PATH is blank; update
the upstream_module function to include a default (*) branch that prints a clear
error to stderr (including the bad provider value from "$1") and exits non‑zero,
and additionally guard the MODULE_PATH usage before invoking controller-gen
(check that MODULE_PATH is non-empty and, if not, print an explanatory error and
exit) so the script fails fast with a helpful message; refer to upstream_module
and MODULE_PATH/controller-gen invocation for where to make these changes.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 153b69f1-c044-4ef1-9906-54c0382495d3
⛔ Files ignored due to path filters (127)
go.sumis excluded by!**/*.sumhack/capi-vendor/agent/go.sumis excluded by!**/*.sumhack/capi-vendor/aws/go.sumis excluded by!**/*.sumhack/capi-vendor/azure/go.sumis excluded by!**/*.sumhack/capi-vendor/gcp/go.sumis excluded by!**/*.sumhack/capi-vendor/ibmcloud/go.sumis excluded by!**/*.sumhack/capi-vendor/kubevirt/go.sumis excluded by!**/*.sumhack/capi-vendor/openstack/go.sumis excluded by!**/*.sumhack/workspace/go.workis excluded by!**/*.workpkg/capi/agent/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/agent/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/exp/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/aws/exp/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/azure/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/gcp/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/ibmcloud/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/ibmcloud/api/v1beta2/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/kubevirt/api/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/openstack/api/v1alpha1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*pkg/capi/openstack/api/v1beta1/zz_generated.deepcopy.gois excluded by!**/zz_generated*.go,!**/zz_generated*vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/CHANGELOG.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/LICENSE.txtis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/README.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/assets.jsonis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/autorest.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/availabilitysets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/build.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/capacityreservationgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/capacityreservations_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/ci.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/client_factory.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceoperatingsystems_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceroleinstances_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudserviceroles_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudservices_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/cloudservicesupdatedomain_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/communitygalleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/constants.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/dedicatedhostgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/dedicatedhosts_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskaccesses_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskencryptionsets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/diskrestorepoint_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/disks_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryapplications_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryapplicationversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/galleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/gallerysharingprofile_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/images_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/loganalytics_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/models.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/models_serde.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/operations_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/options.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/proximityplacementgroups_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/resourceskus_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/responses.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/restorepointcollections_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/restorepoints_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleries_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleryimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sharedgalleryimageversions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/snapshots_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/sshpublickeys_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/time_rfc3339.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/usage_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineextensionimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineimages_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineimagesedgezone_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachineruncommands_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachines_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetrollingupgrades_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesets_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvmextensions_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvmruncommands_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinescalesetvms_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5/virtualmachinesizes_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/.gitignoreis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/.travis.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/CODE_OF_CONDUCT.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/CONTRIBUTING.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/LICENSEis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/README.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/arrays.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/converter.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/doc.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/error.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/numerics.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/patterns.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/types.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/utils.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/validator.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/asaskevich/govalidator/v11/wercker.ymlis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/CHANGELOG.mdis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/LICENSE.txtis excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_client.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateAccessPolicy.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateEncryptionConfig.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_AssociateIdentityProviderConfig.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateCapability.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateEksAnywhereSubscription.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateFargateProfile.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreateNodegroup.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_CreatePodIdentityAssociation.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteCapability.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteEksAnywhereSubscription.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteFargateProfile.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeleteNodegroup.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeletePodIdentityAssociation.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DeregisterCluster.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAccessEntry.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAddon.gois excluded by!vendor/**,!**/vendor/**vendor/github.com/aws/aws-sdk-go-v2/service/eks/api_op_DescribeAddonConfiguration.gois excluded by!vendor/**,!**/vendor/**
📒 Files selected for processing (173)
.gitignore.golangci.ymlMakefilego.modhack/capi-sync-provider.shhack/capi-vendor/agent/go.modhack/capi-vendor/agent/vendor_imports.gohack/capi-vendor/aws/go.modhack/capi-vendor/aws/vendor_imports.gohack/capi-vendor/azure/go.modhack/capi-vendor/azure/vendor_imports.gohack/capi-vendor/gcp/go.modhack/capi-vendor/gcp/vendor_imports.gohack/capi-vendor/ibmcloud/go.modhack/capi-vendor/ibmcloud/vendor_imports.gohack/capi-vendor/kubevirt/go.modhack/capi-vendor/kubevirt/vendor_imports.gohack/capi-vendor/openstack/go.modhack/capi-vendor/openstack/vendor_imports.gohack/copy-capi-types/main.gohack/copy-capi-types/main_test.gopkg/capi/agent/go.modpkg/capi/agent/v1alpha1/agentcluster_types.gopkg/capi/agent/v1alpha1/agentmachine_types.gopkg/capi/agent/v1alpha1/agentmachinetemplate_types.gopkg/capi/agent/v1alpha1/groupversion_info.gopkg/capi/agent/v1alpha1/types.gopkg/capi/agent/v1beta1/agentcluster_types.gopkg/capi/agent/v1beta1/agentmachine_types.gopkg/capi/agent/v1beta1/agentmachinetemplate_types.gopkg/capi/agent/v1beta1/groupversion_info.gopkg/capi/agent/v1beta1/types.gopkg/capi/aws/api/v1beta1/awscluster_types.gopkg/capi/aws/api/v1beta1/awsclustertemplate_types.gopkg/capi/aws/api/v1beta1/awsidentity_types.gopkg/capi/aws/api/v1beta1/awsmachine_types.gopkg/capi/aws/api/v1beta1/awsmachinetemplate_types.gopkg/capi/aws/api/v1beta1/bastion.gopkg/capi/aws/api/v1beta1/conditions_consts.gopkg/capi/aws/api/v1beta1/doc.gopkg/capi/aws/api/v1beta1/groupversion_info.gopkg/capi/aws/api/v1beta1/network_types.gopkg/capi/aws/api/v1beta1/s3bucket.gopkg/capi/aws/api/v1beta1/tags.gopkg/capi/aws/api/v1beta1/types.gopkg/capi/aws/api/v1beta2/awscluster_types.gopkg/capi/aws/api/v1beta2/awsclustertemplate_types.gopkg/capi/aws/api/v1beta2/awsidentity_types.gopkg/capi/aws/api/v1beta2/awsmachine_types.gopkg/capi/aws/api/v1beta2/awsmachinetemplate_types.gopkg/capi/aws/api/v1beta2/bastion.gopkg/capi/aws/api/v1beta2/conditions_consts.gopkg/capi/aws/api/v1beta2/defaults.gopkg/capi/aws/api/v1beta2/doc.gopkg/capi/aws/api/v1beta2/groupversion_info.gopkg/capi/aws/api/v1beta2/network_types.gopkg/capi/aws/api/v1beta2/s3bucket.gopkg/capi/aws/api/v1beta2/tags.gopkg/capi/aws/api/v1beta2/types.gopkg/capi/aws/api/v1beta2/webhooks.gopkg/capi/aws/exp/api/v1beta1/awsmachinepool_types.gopkg/capi/aws/exp/api/v1beta1/conditions_consts.gopkg/capi/aws/exp/api/v1beta1/doc.gopkg/capi/aws/exp/api/v1beta1/finalizers.gopkg/capi/aws/exp/api/v1beta1/groupversion_info.gopkg/capi/aws/exp/api/v1beta1/types.gopkg/capi/aws/exp/api/v1beta2/awsmachinepool_types.gopkg/capi/aws/exp/api/v1beta2/conditions_consts.gopkg/capi/aws/exp/api/v1beta2/doc.gopkg/capi/aws/exp/api/v1beta2/finalizers.gopkg/capi/aws/exp/api/v1beta2/groupversion_info.gopkg/capi/aws/exp/api/v1beta2/types.gopkg/capi/aws/exp/api/v1beta2/validation.gopkg/capi/aws/go.modpkg/capi/azure/api/v1beta1/azureasomanagedcluster_types.gopkg/capi/azure/api/v1beta1/azureasomanagedclustertemplate_types.gopkg/capi/azure/api/v1beta1/azureasomanagedcontrolplane_types.gopkg/capi/azure/api/v1beta1/azureasomanagedcontrolplanetemplate_types.gopkg/capi/azure/api/v1beta1/azureasomanagedmachinepool_types.gopkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.gopkg/capi/azure/api/v1beta1/azurecluster_default.gopkg/capi/azure/api/v1beta1/azurecluster_types.gopkg/capi/azure/api/v1beta1/azurecluster_validation.gopkg/capi/azure/api/v1beta1/azureclusteridentity_types.gopkg/capi/azure/api/v1beta1/azureclustertemplate_default.gopkg/capi/azure/api/v1beta1/azureclustertemplate_types.gopkg/capi/azure/api/v1beta1/azureclustertemplate_validation.gopkg/capi/azure/api/v1beta1/azureimage_validation.gopkg/capi/azure/api/v1beta1/azuremachine_default.gopkg/capi/azure/api/v1beta1/azuremachine_types.gopkg/capi/azure/api/v1beta1/azuremachine_validation.gopkg/capi/azure/api/v1beta1/azuremachinetemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedcluster_types.gopkg/capi/azure/api/v1beta1/azuremanagedclustertemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_default.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_types.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_default.gopkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_types.gopkg/capi/azure/api/v1beta1/azuremanagedmachinepool_types.gopkg/capi/azure/api/v1beta1/azuremanagedmachinepooltemplate_types.gopkg/capi/azure/api/v1beta1/consts.gopkg/capi/azure/api/v1beta1/doc.gopkg/capi/azure/api/v1beta1/groupversion_info.gopkg/capi/azure/api/v1beta1/tags.gopkg/capi/azure/api/v1beta1/types.gopkg/capi/azure/api/v1beta1/types_class.gopkg/capi/azure/api/v1beta1/types_template.gopkg/capi/azure/go.modpkg/capi/gcp/api/v1beta1/doc.gopkg/capi/gcp/api/v1beta1/endpoints.gopkg/capi/gcp/api/v1beta1/gcpcluster_types.gopkg/capi/gcp/api/v1beta1/gcpclustertemplate_types.gopkg/capi/gcp/api/v1beta1/gcpmachine_types.gopkg/capi/gcp/api/v1beta1/gcpmachinetemplate_types.gopkg/capi/gcp/api/v1beta1/groupversion_info.gopkg/capi/gcp/api/v1beta1/labels.gopkg/capi/gcp/api/v1beta1/tags.gopkg/capi/gcp/api/v1beta1/types.gopkg/capi/gcp/go.modpkg/capi/ibmcloud/api/v1beta1/conditions_consts.gopkg/capi/ibmcloud/api/v1beta1/doc.gopkg/capi/ibmcloud/api/v1beta1/groupversion_info.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervscluster_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsimage_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsmachine_types.gopkg/capi/ibmcloud/api/v1beta1/ibmpowervsmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpccluster_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpcmachine_types.gopkg/capi/ibmcloud/api/v1beta1/ibmvpcmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta1/types.gopkg/capi/ibmcloud/api/v1beta2/conditions_consts.gopkg/capi/ibmcloud/api/v1beta2/doc.gopkg/capi/ibmcloud/api/v1beta2/groupversion_info.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervscluster_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsimage_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsmachine_types.gopkg/capi/ibmcloud/api/v1beta2/ibmpowervsmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpccluster_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcclustertemplate_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcmachine_types.gopkg/capi/ibmcloud/api/v1beta2/ibmvpcmachinetemplate_types.gopkg/capi/ibmcloud/api/v1beta2/types.gopkg/capi/ibmcloud/go.modpkg/capi/kubevirt/api/v1alpha1/condition_consts.gopkg/capi/kubevirt/api/v1alpha1/doc.gopkg/capi/kubevirt/api/v1alpha1/groupversion_info.gopkg/capi/kubevirt/api/v1alpha1/kubevirtcluster_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtclustertemplate_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtmachine_types.gopkg/capi/kubevirt/api/v1alpha1/kubevirtmachinetemplate_types.gopkg/capi/kubevirt/go.modpkg/capi/openstack/api/v1alpha1/conditions_consts.gopkg/capi/openstack/api/v1alpha1/doc.gopkg/capi/openstack/api/v1alpha1/groupversion_info.gopkg/capi/openstack/api/v1alpha1/openstackfloatingippool_types.gopkg/capi/openstack/api/v1alpha1/openstackserver_types.gopkg/capi/openstack/api/v1alpha1/types.gopkg/capi/openstack/api/v1beta1/conditions_consts.gopkg/capi/openstack/api/v1beta1/doc.gopkg/capi/openstack/api/v1beta1/groupversion_info.gopkg/capi/openstack/api/v1beta1/identity_types.gopkg/capi/openstack/api/v1beta1/openstackcluster_types.gopkg/capi/openstack/api/v1beta1/openstackclustertemplate_types.gopkg/capi/openstack/api/v1beta1/openstackmachine_types.gopkg/capi/openstack/api/v1beta1/openstackmachinetemplate_types.gopkg/capi/openstack/api/v1beta1/types.gopkg/capi/openstack/go.modpkg/capi/openstack/pkg/utils/errors/errors.gopkg/capi/openstack/pkg/utils/errors/terminal.gopkg/capi/openstack/pkg/utils/optional/types.gosupport/api/capi_types.go
💤 Files with no reviewable changes (2)
- pkg/capi/aws/api/v1beta1/network_types.go
- pkg/capi/aws/api/v1beta1/tags.go
✅ Files skipped from review due to trivial changes (10)
- .gitignore
- hack/capi-vendor/agent/go.mod
- hack/capi-vendor/azure/vendor_imports.go
- hack/capi-vendor/aws/vendor_imports.go
- pkg/capi/azure/api/v1beta1/groupversion_info.go
- .golangci.yml
- pkg/capi/agent/go.mod
- hack/capi-vendor/openstack/vendor_imports.go
- pkg/capi/azure/api/v1beta1/consts.go
- pkg/capi/aws/go.mod
🚧 Files skipped from review as they are similar to previous changes (59)
- hack/capi-vendor/gcp/go.mod
- hack/capi-vendor/kubevirt/vendor_imports.go
- pkg/capi/azure/api/v1beta1/azureasomanagedclustertemplate_types.go
- pkg/capi/azure/api/v1beta1/doc.go
- pkg/capi/agent/v1beta1/groupversion_info.go
- hack/capi-vendor/ibmcloud/go.mod
- hack/capi-vendor/aws/go.mod
- pkg/capi/aws/api/v1beta1/s3bucket.go
- pkg/capi/agent/v1beta1/agentmachine_types.go
- pkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_default.go
- hack/capi-vendor/gcp/vendor_imports.go
- hack/capi-vendor/agent/vendor_imports.go
- hack/capi-vendor/openstack/go.mod
- pkg/capi/azure/api/v1beta1/azureclustertemplate_default.go
- pkg/capi/azure/api/v1beta1/azuremanagedclustertemplate_types.go
- hack/capi-vendor/ibmcloud/vendor_imports.go
- hack/capi-vendor/azure/go.mod
- pkg/capi/aws/api/v1beta2/groupversion_info.go
- pkg/capi/aws/api/v1beta2/s3bucket.go
- pkg/capi/aws/api/v1beta2/awsmachinetemplate_types.go
- hack/capi-vendor/kubevirt/go.mod
- pkg/capi/azure/api/v1beta1/azureasomanagedmachinepooltemplate_types.go
- pkg/capi/azure/api/v1beta1/azureclustertemplate_validation.go
- pkg/capi/azure/api/v1beta1/azuremanagedmachinepooltemplate_types.go
- pkg/capi/azure/api/v1beta1/azureclustertemplate_types.go
- pkg/capi/aws/api/v1beta2/doc.go
- pkg/capi/azure/api/v1beta1/azuremanagedcontrolplanetemplate_types.go
- pkg/capi/azure/api/v1beta1/azuremanagedcluster_types.go
- pkg/capi/agent/v1beta1/agentcluster_types.go
- pkg/capi/agent/v1beta1/agentmachinetemplate_types.go
- pkg/capi/azure/api/v1beta1/types_class.go
- pkg/capi/azure/api/v1beta1/azureasomanagedcontrolplane_types.go
- pkg/capi/azure/api/v1beta1/azureasomanagedmachinepool_types.go
- pkg/capi/azure/api/v1beta1/types_template.go
- pkg/capi/azure/api/v1beta1/tags.go
- pkg/capi/aws/api/v1beta2/defaults.go
- pkg/capi/aws/api/v1beta2/awscluster_types.go
- pkg/capi/azure/api/v1beta1/azuremachine_default.go
- pkg/capi/azure/api/v1beta1/types.go
- pkg/capi/aws/api/v1beta2/awsmachine_types.go
- pkg/capi/azure/api/v1beta1/azureclusteridentity_types.go
- pkg/capi/azure/api/v1beta1/azureasomanagedcluster_types.go
- pkg/capi/azure/api/v1beta1/azuremachine_validation.go
- pkg/capi/aws/api/v1beta2/webhooks.go
- pkg/capi/aws/api/v1beta2/awsidentity_types.go
- pkg/capi/aws/api/v1beta2/tags.go
- pkg/capi/aws/api/v1beta2/awsclustertemplate_types.go
- pkg/capi/aws/api/v1beta2/types.go
- pkg/capi/aws/api/v1beta2/bastion.go
- go.mod
- pkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_default.go
- pkg/capi/aws/api/v1beta2/conditions_consts.go
- pkg/capi/azure/api/v1beta1/azuremachinetemplate_types.go
- hack/copy-capi-types/main_test.go
- pkg/capi/azure/api/v1beta1/azuremachine_types.go
- pkg/capi/azure/api/v1beta1/azuremanagedcontrolplane_types.go
- pkg/capi/aws/api/v1beta2/network_types.go
- pkg/capi/azure/api/v1beta1/azurecluster_default.go
- pkg/capi/azure/api/v1beta1/azurecluster_validation.go
|
/pipeline required |
|
Scheduling tests matching the |
|
please let's make sure to capture this new process here https://github.com/openshift/hypershift/blob/main/DEVELOPMENT.md#multi-module-structure |
Test Failure Analysis CompleteJob Information
Test Failure AnalysisErrorSummaryNo Prow CI jobs have executed for this PR. The Root CauseThe sole file with a merge conflict is The conflict is purely in documentation — no source code, Because tide detects this conflict, it sets the commit status to A secondary merge blocker exists: the Recommendations
Evidence
|
Copy CAPI infrastructure provider API types from vendored sources into pkg/capi/<provider>/<version>/ using an AST-based tool that strips external dependencies not needed by HyperShift. This decouples the Go module dependency on CAPI infrastructure providers so they no longer require simultaneous bumps during CAPI version upgrades. All 7 providers (AWS, Azure, GCP, IBM Cloud, KubeVirt, OpenStack, Agent) are now local. Makefile CRD generation targets, codespell, and golangci-lint are updated to use the local paths. Generated CRDs are identical to main. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
@csrwng: The following test failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
| # Download a module into the cache and print its directory. | ||
| mod_cache_dir() { | ||
| local module="$1" | ||
| (cd "$MOD_DIR" && GO111MODULE=on GOWORK=off GOFLAGS= go mod download -json "$module") | jq -r '.Dir' |
There was a problem hiding this comment.
I think it's cleaner to put GOFLAGS='' also in line 139
Summary
Decouples HyperShift's Go module dependency on CAPI infrastructure providers (AWS, Azure, GCP, IBM Cloud, KubeVirt, OpenStack, Agent) so that bumping K8s core dependencies no longer requires waiting for all upstream CAPI providers to release compatible versions first.
Instead of importing CAPI provider modules directly (which pulls in their full transitive dependency trees including specific K8s versions), this PR copies only the API types HyperShift needs into local
pkg/capi/<provider>/packages. Each provider gets its own Go module declaring the upstream module name, and the maingo.modusesreplacedirectives to redirect imports to the local copies. This preserves upstream import paths throughout the codebase.Key changes
hack/copy-capi-types/main.go): strips unused functions, defaults, and validation while preserving types, constants, and deepcopyhack/capi-sync-provider.sh): re-syncs types from a specific upstream version on demandhack/capi-vendor/<provider>/): pin upstream versions independently, used only by the sync scripthack/workspace/go.work): enables controller-gen CRD and deepcopy generation across provider modules.syncedsentinel filesImpact
Supersedes #8697.
Jira: https://redhat.atlassian.net/browse/CNTRLPLANE-3610
Test plan
make verifypassesmake testpassesmake capi-sync-forceround-trips cleanly (no diff)Summary by CodeRabbit
New Features
Chores