From b256f1f4a1897262b0c190ab286df45f6073c3f3 Mon Sep 17 00:00:00 2001 From: Robert Findley Date: Mon, 19 Sep 2022 13:58:40 -0400 Subject: [PATCH] gopls/internal/lsp/cache: remove distracting "safe trimming" log This log is noisy and of little value, often confusing users. Remove it. Updates golang/go#51947 Change-Id: I2b2dff8383de52467bf3953d3efda4e6d4b792dd Reviewed-on: https://go-review.googlesource.com/c/tools/+/431836 Reviewed-by: Heschi Kreinick gopls-CI: kokoro TryBot-Result: Gopher Robot Run-TryBot: Robert Findley --- gopls/internal/lsp/cache/check.go | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/gopls/internal/lsp/cache/check.go b/gopls/internal/lsp/cache/check.go index 1fbd9c002d..3974f516f8 100644 --- a/gopls/internal/lsp/cache/check.go +++ b/gopls/internal/lsp/cache/check.go @@ -21,11 +21,11 @@ import ( "golang.org/x/sync/errgroup" "golang.org/x/tools/go/ast/astutil" "golang.org/x/tools/go/packages" - "golang.org/x/tools/internal/event" - "golang.org/x/tools/internal/bug" - "golang.org/x/tools/internal/event/tag" "golang.org/x/tools/gopls/internal/lsp/protocol" "golang.org/x/tools/gopls/internal/lsp/source" + "golang.org/x/tools/internal/bug" + "golang.org/x/tools/internal/event" + "golang.org/x/tools/internal/event/tag" "golang.org/x/tools/internal/memoize" "golang.org/x/tools/internal/packagesinternal" "golang.org/x/tools/internal/span" @@ -355,8 +355,6 @@ func typeCheckImpl(ctx context.Context, snapshot *snapshot, goFiles, compiledGoF missing, unexpected = filter.ProcessErrors(pkg.typeErrors) } if len(unexpected) != 0 || len(missing) != 0 { - // TODO(rfindley): remove this distracting log - event.Log(ctx, fmt.Sprintf("falling back to safe trimming due to type errors: %v or still-missing identifiers: %v", unexpected, missing), tag.Package.Of(string(m.ID))) pkg, err = doTypeCheck(ctx, snapshot, goFiles, compiledGoFiles, m, mode, deps, nil) if err != nil { return nil, err