8000 Added `BoardIdentify` gRPC call. by cmaglie · Pull Request #2794 · arduino/arduino-cli · GitHub
[go: up one dir, main page]

Skip to content

Added BoardIdentify gRPC call. #2794

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Jan 13, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Moved code for better readability
  • Loading branch information
cmaglie committed Jan 7, 2025
commit 056c93d371523c2c0226b587bca5eb2ce441ad93
11 changes: 5 additions & 6 deletions commands/service_board_list.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,6 @@ import (
// In case of errors partial results from discoveries that didn't fail
// are returned.
func (s *arduinoCoreServerImpl) BoardList(ctx context.Context, req *rpc.BoardListRequest) (*rpc.BoardListResponse, error) {
pme, release, err := instances.GetPackageManagerExplorer(req.GetInstance())
if err != nil {
return nil, err
}
defer release()

var fqbnFilter *fqbn.FQBN
if f := req.GetFqbn(); f != "" {
var err error
Expand All @@ -48,6 +42,11 @@ func (s *arduinoCoreServerImpl) BoardList(ctx context.Context, req *rpc.BoardLis
}
}

pme, release, err := instances.GetPackageManagerExplorer(req.GetInstance())
if err != nil {
return nil, err
}
defer release()
dm := pme.DiscoveryManager()
warnings := f.Map(dm.Start(), (error).Error)
time.Sleep(time.Duration(req.GetTimeout()) * time.Millisecond)
Expand Down
0