From 57b1e65ac587cb4a6ba31800cec4004a854e59a4 Mon Sep 17 00:00:00 2001 From: Ye Chen Date: Tue, 7 Jul 2026 16:24:25 -0400 Subject: [PATCH 1/2] fix v2 --- interfaces.go | 6 +++--- test/unit/rdma_vpc_test.go | 4 ++-- vpc.go | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/interfaces.go b/interfaces.go index 9d0481e3c..cd88b2974 100644 --- a/interfaces.go +++ b/interfaces.go @@ -177,9 +177,9 @@ type LinodeInstanceInterfaceCreateOptions struct { } type LinodeInterfaceUpdateOptions struct { - DefaultRoute *InterfaceDefaultRoute `json:"default_route,omitempty"` - Public *PublicInterfaceCreateOptions `json:"public,omitempty"` - VPC *VPCInterfaceUpdateOptions `json:"vpc,omitempty"` + DefaultRoute *InterfaceDefaultRouteUpdateOptions `json:"default_route,omitempty"` + Public *PublicInterfaceCreateOptions `json:"public,omitempty"` + VPC *VPCInterfaceUpdateOptions `json:"vpc,omitempty"` // NOTE: RDMA VPC interfaces may not currently be available to all users. RDMAVPC *RDMAVPCInterfaceUpdateOptions `json:"rdma_vpc,omitzero"` diff --git a/test/unit/rdma_vpc_test.go b/test/unit/rdma_vpc_test.go index 5c4ee5ca9..befa46c5e 100644 --- a/test/unit/rdma_vpc_test.go +++ b/test/unit/rdma_vpc_test.go @@ -6,7 +6,7 @@ import ( "testing" "github.com/jarcoal/httpmock" - "github.com/linode/linodego" + "github.com/linode/linodego/v2" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) @@ -294,7 +294,7 @@ func TestInstance_CreateWithLinodeInterfaces_BackwardsCompatible(t *testing.T) { VPC: &linodego.VPCInterfaceCreateOptions{ SubnetID: 4, IPv4: &linodego.VPCInterfaceIPv4CreateOptions{ - Addresses: &[]linodego.VPCInterfaceIPv4AddressCreateOptions{ + Addresses: []linodego.VPCInterfaceIPv4AddressCreateOptions{ { Address: linodego.Pointer("10.0.0.5"), Primary: linodego.Pointer(true), diff --git a/vpc.go b/vpc.go index ff2e62e2e..42812fdf1 100644 --- a/vpc.go +++ b/vpc.go @@ -63,7 +63,7 @@ type VPCCreateOptions struct { Label string `json:"label"` Description string `json:"description,omitzero"` Region string `json:"region"` - + // This field is omitted by the API for customers that do not have // access to the GPUDirect RDMA functionality. // NOTE: RDMA VPCs may not currently be available to all users. From b52e70db7a79924cb7b589fad4ea06ebb4357b6c Mon Sep 17 00:00:00 2001 From: Ye Chen Date: Tue, 7 Jul 2026 16:32:41 -0400 Subject: [PATCH 2/2] udpate --- interfaces.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/interfaces.go b/interfaces.go index cd88b2974..a5c5bb5ba 100644 --- a/interfaces.go +++ b/interfaces.go @@ -177,9 +177,9 @@ type LinodeInstanceInterfaceCreateOptions struct { } type LinodeInterfaceUpdateOptions struct { - DefaultRoute *InterfaceDefaultRouteUpdateOptions `json:"default_route,omitempty"` - Public *PublicInterfaceCreateOptions `json:"public,omitempty"` - VPC *VPCInterfaceUpdateOptions `json:"vpc,omitempty"` + DefaultRoute *InterfaceDefaultRouteUpdateOptions `json:"default_route,omitzero"` + Public *PublicInterfaceCreateOptions `json:"public,omitzero"` + VPC *VPCInterfaceUpdateOptions `json:"vpc,omitzero"` // NOTE: RDMA VPC interfaces may not currently be available to all users. RDMAVPC *RDMAVPCInterfaceUpdateOptions `json:"rdma_vpc,omitzero"`