From d95aa61a0d89cbc5d30b8ba80928616e4a879827 Mon Sep 17 00:00:00 2001 From: Mauri de Souza Meneguzzo Date: Wed, 2 Oct 2024 08:43:01 -0300 Subject: [PATCH] fix(logp): TestConfigureWithCore fails with Go 1.24 (#233) The cmd/vet in Go 1.24 reports printf calls with non-const format and no args, causing one test in logp to fail. See https://github.com/golang/go/issues/60529. ``` $ go install golang.org/dl/gotip@latest $ gotip download $ gotip test ./logp -count=1 logp/core_test.go:714:7: non-constant format string in call to github.com/elastic/elastic-agent-libs/logp.Info FAIL github.com/elastic/elastic-agent-libs/logp [build failed] ``` --- logp/core_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/logp/core_test.go b/logp/core_test.go index aa48784..cac0ce2 100644 --- a/logp/core_test.go +++ b/logp/core_test.go @@ -711,7 +711,7 @@ func TestConfigureWithCore(t *testing.T) { if err != nil { t.Fatalf("Unexpected err: %s", err) } - Info(testMsg) + Info("The quick brown %s jumped over the lazy %s.", "fox", "dog") var r map[string]interface{} err = json.Unmarshal(b.Bytes(), &r)