From 34765c83ab952f8ae7a421ccacd3389e34c24694 Mon Sep 17 00:00:00 2001 From: Camden Cheek Date: Tue, 16 Apr 2024 10:58:31 -0600 Subject: [PATCH] fix debug score printing --- internal/e2e/e2e_rank_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/e2e/e2e_rank_test.go b/internal/e2e/e2e_rank_test.go index bb6d421b7..1e4cdca6e 100644 --- a/internal/e2e/e2e_rank_test.go +++ b/internal/e2e/e2e_rank_test.go @@ -311,7 +311,7 @@ func marshalMatches(w io.Writer, rq rankingQuery, q query.Q, files []zoekt.FileM chunks, hidden := splitAtIndex(f.ChunkMatches, chunkMatchesPerFile) for _, m := range chunks { - _, _ = fmt.Fprintf(w, "%d:%s%s", m.ContentStart.LineNumber, string(m.Content), addTabIfNonEmpty(m.DebugScore)) + _, _ = fmt.Fprintf(w, "%d:%s%s\n", m.ContentStart.LineNumber, strings.TrimRight(string(m.Content), "\n"), addTabIfNonEmpty(m.DebugScore)) } if len(hidden) > 0 {