Skip to content

Commit 4da134e

Browse files
authored
chore(deps): bump golang.org/x/text from 0.28.0 to 0.31.0 (#3913)
Bumps [golang.org/x/text](https://github.com/golang/text) from 0.28.0 to 0.31.0. Ref: #3902 Signed-off-by: Ryan Johnson <ryan.johnson@broadcom.com>
1 parent 4a6daa1 commit 4da134e

14 files changed

Lines changed: 31 additions & 32 deletions

File tree

.github/workflows/govmomi-go-tests.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
name: Run Unit Tests
1616
strategy:
1717
matrix:
18-
go-version: ["1.23", "1.24"]
18+
go-version: ["1.24", "1.25"]
1919
platform: [ubuntu-latest]
2020
fail-fast: false
2121

.github/workflows/govmomi-govc-tests.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
strategy:
2121
fail-fast: false
2222
matrix:
23-
go-version: ["1.23"]
23+
go-version: ["1.24"]
2424
platform: [ubuntu-latest]
2525
cmd: [govc-test]
2626
experimental: [false]
@@ -62,7 +62,7 @@ jobs:
6262
name: Verify Updated Docs
6363
strategy:
6464
matrix:
65-
go-version: ["1.23"]
65+
go-version: ["1.24"]
6666
platform: [ubuntu-latest]
6767
runs-on: ${{ matrix.platform }}
6868
timeout-minutes: 3

cli/dvs/portgroup/info.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ func printTable(trafficRuleSet map[int]map[int]trafficRule, portID int) {
138138
tabWidthInt := 22
139139
tabWidth := fmt.Sprintf("%d", tabWidthInt)
140140
headLen := 9*(tabWidthInt+2) - 1
141-
fmt.Printf("+" + strings.Repeat("-", headLen) + "+\n")
141+
fmt.Print("+" + strings.Repeat("-", headLen) + "+\n")
142142
format := "| %-" + tabWidth +
143143
"s| %-" + tabWidth +
144144
"s| %-" + tabWidth +
@@ -159,7 +159,7 @@ func printTable(trafficRuleSet map[int]map[int]trafficRule, portID int) {
159159
"SourceIpPort",
160160
"DestinationAddress",
161161
"DestinationIpPort")
162-
fmt.Printf("+" + strings.Repeat("-", headLen) + "+\n")
162+
fmt.Print("+" + strings.Repeat("-", headLen) + "+\n")
163163
for _, id := range keys {
164164
fmt.Printf(format,
165165
fmt.Sprintf("%d", id),
@@ -172,7 +172,7 @@ func printTable(trafficRuleSet map[int]map[int]trafficRule, portID int) {
172172
trafficRuleSet[portID][id].DestinationAddress,
173173
trafficRuleSet[portID][id].DestinationIpPort)
174174
}
175-
fmt.Printf("+" + strings.Repeat("-", headLen) + "+\n")
175+
fmt.Print("+" + strings.Repeat("-", headLen) + "+\n")
176176
}
177177

178178
func (r *infoResult) Write(w io.Writer) error {

cli/task/recent.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ type taskResult struct {
300300
}
301301

302302
func (t *taskResult) WriteHeader(w io.Writer) {
303-
fmt.Fprintf(w, t.format("Task", "Target", "Initiator", "Queued", "Started", "Completed", "Result"))
303+
fmt.Fprint(w, t.format("Task", "Target", "Initiator", "Queued", "Started", "Completed", "Result"))
304304
}
305305

306306
func (t *taskResult) Write(w io.Writer) error {

go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/vmware/govmomi
22

3-
go 1.23.0 // required for slices/maps package and built-in clear function
3+
go 1.24.0 // required for slices/maps package and built-in clear function
44

55
require (
66
github.com/a8m/tree v0.0.0-20240104212747-2c8764a5f17e
@@ -11,7 +11,7 @@ require (
1111
github.com/stretchr/testify v1.11.1
1212
github.com/vmware/vmw-guestinfo v0.0.0-20220317130741-510905f0efa3
1313
github.com/xlab/treeprint v1.2.0
14-
golang.org/x/text v0.28.0
14+
golang.org/x/text v0.31.0
1515
)
1616

1717
require (

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ github.com/vmware/vmw-guestinfo v0.0.0-20220317130741-510905f0efa3 h1:v6jG/tdl4O
2929
github.com/vmware/vmw-guestinfo v0.0.0-20220317130741-510905f0efa3/go.mod h1:CSBTxrhePCm0cmXNKDGeu+6bOQzpaEklfCqEpn89JWk=
3030
github.com/xlab/treeprint v1.2.0 h1:HzHnuAF1plUN2zGlAFHbSQP2qJ0ZAD3XF5XD7OesXRQ=
3131
github.com/xlab/treeprint v1.2.0/go.mod h1:gj5Gd3gPdKtR1ikdDK6fnFLdmIS0X30kTTuNd/WEJu0=
32-
golang.org/x/text v0.28.0 h1:rhazDwis8INMIwQ4tpjLDzUhx6RlXqZNPEM0huQojng=
33-
golang.org/x/text v0.28.0/go.mod h1:U8nCwOR8jO/marOQ0QbDiOngZVEBB7MAiitBuMjXiNU=
32+
golang.org/x/text v0.31.0 h1:aC8ghyu4JhP8VojJ2lEHBnochRno1sgL6nEi9WGFGMM=
33+
golang.org/x/text v0.31.0/go.mod h1:tKRAlv61yKIjGGHX/4tP1LTbc13YSec1pxVEWXzfoeM=
3434
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
3535
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
3636
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

govc/go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/vmware/govmomi/govc
22

3-
go 1.23.0
3+
go 1.24.0
44

55
replace github.com/vmware/govmomi => ../
66

@@ -13,5 +13,5 @@ require (
1313
github.com/kr/text v0.2.0 // indirect
1414
github.com/rogpeppe/go-internal v1.12.0 // indirect
1515
github.com/xlab/treeprint v1.2.0 // indirect
16-
golang.org/x/text v0.28.0 // indirect
16+
golang.org/x/text v0.31.0 // indirect
1717
)

govc/go.sum

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU
2020
github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4=
2121
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
2222
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
23-
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
24-
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
23+
github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U=
24+
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
2525
github.com/xlab/treeprint v1.2.0 h1:HzHnuAF1plUN2zGlAFHbSQP2qJ0ZAD3XF5XD7OesXRQ=
2626
github.com/xlab/treeprint v1.2.0/go.mod h1:gj5Gd3gPdKtR1ikdDK6fnFLdmIS0X30kTTuNd/WEJu0=
27-
golang.org/x/text v0.28.0 h1:rhazDwis8INMIwQ4tpjLDzUhx6RlXqZNPEM0huQojng=
28-
golang.org/x/text v0.28.0/go.mod h1:U8nCwOR8jO/marOQ0QbDiOngZVEBB7MAiitBuMjXiNU=
27+
golang.org/x/text v0.31.0 h1:aC8ghyu4JhP8VojJ2lEHBnochRno1sgL6nEi9WGFGMM=
28+
golang.org/x/text v0.31.0/go.mod h1:tKRAlv61yKIjGGHX/4tP1LTbc13YSec1pxVEWXzfoeM=
2929
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
3030
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
3131
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=

list/lister.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ func (l Lister) List(ctx context.Context) ([]Element, error) {
152152
case "VmwareDistributedVirtualSwitch", "DistributedVirtualSwitch":
153153
return l.ListDistributedVirtualSwitch(ctx)
154154
default:
155-
return nil, fmt.Errorf("cannot traverse type " + l.Reference.Type)
155+
return nil, fmt.Errorf("cannot traverse type %s", l.Reference.Type)
156156
}
157157
}
158158

simulator/container_virtual_machine.go

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import (
88
"archive/tar"
99
"encoding/hex"
1010
"encoding/json"
11-
"errors"
1211
"fmt"
1312
"io"
1413
"log"
@@ -318,10 +317,9 @@ func (svm *simVM) start(ctx *Context) error {
318317
// Wait for the task to complete and see if there is an error.
319318
task.Wait()
320319
if task.Info.Error != nil {
321-
msg := fmt.Sprintf("failed to destroy vm: err=%v", *task.Info.Error)
322-
svm.vm.logPrintf(msg)
323-
324-
return errors.New(msg)
320+
err := fmt.Errorf("failed to destroy vm: %v", task.Info.Error)
321+
svm.vm.logPrintf("%s", err.Error())
322+
return err
325323
}
326324
}
327325

0 commit comments

Comments
 (0)