Skip to content

Commit

Permalink
dep fix
Browse files Browse the repository at this point in the history
  • Loading branch information
mcy committed Oct 10, 2024
1 parent 5284584 commit 029cbcf
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
11 changes: 1 addition & 10 deletions private/buf/buflsp/buflsp.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import (
"sync"
"sync/atomic"

"github.com/bufbuild/buf/private/buf/bufcli"
"github.com/bufbuild/buf/private/buf/bufctl"
"github.com/bufbuild/buf/private/bufpkg/bufcheck"
"github.com/bufbuild/buf/private/pkg/app/appext"
Expand All @@ -41,6 +40,7 @@ import (
// Returns a context for managing the server.
func Serve(
ctx context.Context,
wktBucket storage.ReadBucket,
container appext.Container,
controller bufctl.Controller,
checkClient bufcheck.Client,
Expand All @@ -58,15 +58,6 @@ func Serve(
return nil, err
}

wktStore, err := bufcli.NewWKTStore(container)
if err != nil {
return nil, err
}
wktBucket, err := wktStore.GetBucket(ctx)
if err != nil {
return nil, err
}

conn := jsonrpc2.NewConn(stream)
lsp := &lsp{
conn: conn,
Expand Down
11 changes: 10 additions & 1 deletion private/buf/cmd/buf/command/beta/lsp/lsp.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,15 @@ func run(
return err
}

wktStore, err := bufcli.NewWKTStore(container)
if err != nil {
return err
}
wktBucket, err := wktStore.GetBucket(ctx)
if err != nil {
return err
}

controller, err := bufcli.NewController(container)
if err != nil {
return err
Expand All @@ -114,7 +123,7 @@ func run(
return err
}

conn, err := buflsp.Serve(ctx, container, controller, checkClient, jsonrpc2.NewStream(transport))
conn, err := buflsp.Serve(ctx, wktBucket, container, controller, checkClient, jsonrpc2.NewStream(transport))
if err != nil {
return err
}
Expand Down

0 comments on commit 029cbcf

Please sign in to comment.