Skip to content

Commit

Permalink
Revert "internal/lsp/cache: disable GOPACKAGESDRIVER"
Browse files Browse the repository at this point in the history
Now that https://github.com/bazelbuild/rules_go has a working prototype of a `GOPACKAGESDRIVER`, it may be time to revert that commit.

The draft implementation is at bazel-contrib/rules_go#2858.

Change-Id: Ia738e8be448d936f8a3b2b421d0a765f94bbff52
GitHub-Last-Rev: 0df6c91
GitHub-Pull-Request: golang#297
Reviewed-on: https://go-review.googlesource.com/c/tools/+/307169
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Heschi Kreinick <heschi@google.com>
Trust: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
  • Loading branch information
steeve authored and heschi committed Apr 6, 2021
1 parent 35a9159 commit c602466
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions internal/lsp/cache/snapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -200,14 +200,10 @@ func (s *snapshot) config(ctx context.Context, inv *gocommand.Invocation) *packa
verboseOutput := s.view.options.VerboseOutput
s.view.optionsMu.Unlock()

// Forcibly disable GOPACKAGESDRIVER. It's incompatible with the
// packagesinternal APIs we use, and we really only support the go command
// anyway.
env := append(append([]string{}, inv.Env...), "GOPACKAGESDRIVER=off")
cfg := &packages.Config{
Context: ctx,
Dir: inv.WorkingDir,
Env: env,
Env: inv.Env,
BuildFlags: inv.BuildFlags,
Mode: packages.NeedName |
packages.NeedFiles |
Expand Down

0 comments on commit c602466

Please sign in to comment.