From e7bdc8819a19f06321d300719224abb2d8567b4a Mon Sep 17 00:00:00 2001 From: Michael Anthony Knyszek Date: Mon, 25 Mar 2024 17:00:55 +0000 Subject: [PATCH] internal/trace/v2: fix reader version for dumping text output There was recently a failure that we don't have a trace dump for because the reader was passed Go122 but traces have moved onto version Go123. Use version.Current to prevent this from happening again in the future. Change-Id: I4f8b3c3ea5bad61a07839a697cd5d7793d62ea52 Reviewed-on: https://go-review.googlesource.com/c/go/+/574216 LUCI-TryBot-Result: Go LUCI Reviewed-by: Carlos Amedee --- src/internal/trace/v2/reader_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/internal/trace/v2/reader_test.go b/src/internal/trace/v2/reader_test.go index 393e1c80b0..121f0174ed 100644 --- a/src/internal/trace/v2/reader_test.go +++ b/src/internal/trace/v2/reader_test.go @@ -133,7 +133,7 @@ func dumpTraceToText(t *testing.T, b []byte) string { t.Fatalf("dumping trace: %v", err) } var sb strings.Builder - tw, err := raw.NewTextWriter(&sb, version.Go122) + tw, err := raw.NewTextWriter(&sb, version.Current) if err != nil { t.Fatalf("dumping trace: %v", err) }