arduino-language-server icon indicating copy to clipboard operation
arduino-language-server copied to clipboard

Unexpected error from LS when suggesting

Open kittaakos opened this issue 3 years ago • 0 comments

Describe the problem

Error:

errors.ts:26 Uncaught Error: Cannot read properties of null (reading 'map')

TypeError: Cannot read properties of null (reading 'map')
    at asCompletionResult (/Users/a.kitta/dev/g…ist/bundle.js:11434)
    at errors.ts:26

To reproduce

Broken snippet:

#include <ArduinoGraphics.h>
#include <Arduino_MKRRGB.h>
#include <

void setup() {
  MATRIX.begin();

}

void loop() {
}

Then complete the < with > in the third line so you get:

#include <ArduinoGraphics.h>
#include <Arduino_MKRRGB.h>
#include <>

void setup() {
  MATRIX.begin();

}

void loop() {
}

Expected behavior

Does not throw.

Arduino Language Server version

HEAD of the main branch.

Arduino CLI version

From sources: cmaglie:skip_lib_search_result

Operating system

macOS

Operating system version

12.3.1

Additional context

No response

Issue checklist

  • [X] I searched for previous reports in the issue tracker
  • [X] I verified the problem still occurs when using the latest version
  • [X] My report contains all necessary details

kittaakos avatar Jun 23 '22 10:06 kittaakos