IDE hangs on startup: "Error loading hardware platform: discovery teensy:teensy-discovery not found"

hey there similar issue here's what im getting:

Last login: Tue Sep 12 21:05:24 on ttys000
oliveyu@10-18-213-228 ~ % 
oliveyu@10-18-213-228 ~ % "/Applications/Arduino IDE.app/Contents/MacOS/Arduino IDE"

Arduino IDE 2.2.1
Checking for frontend application configuration customizations. Module path: /Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/electron-main.js, destination 'package.json': /Applications/Arduino IDE.app/Contents/Resources/app/package.json
Setting 'theia.frontend.config.appVersion' application configuration value to: "2.2.1" (type of string)
Setting 'theia.frontend.config.cliVersion' application configuration value to: "0.34.0" (type of string)
Setting 'theia.frontend.config.buildDate' application configuration value to: "2023-08-31T13:53:43.373Z" (type of string)
Frontend application configuration after modifications: {"applicationName":"Arduino IDE","defaultTheme":{"light":"arduino-theme","dark":"arduino-theme-dark"},"defaultIconTheme":"none","electron":{"windowOptions":{}},"defaultLocale":"","validatePreferencesSchema":false,"preferences":{"window.title":"${rootName}${activeEditorShort}${appName}","files.autoSave":"afterDelay","editor.minimap.enabled":false,"editor.tabSize":2,"editor.scrollBeyondLastLine":false,"editor.quickSuggestions":{"other":false,"comments":false,"strings":false},"editor.maxTokenizationLineLength":500,"editor.bracketPairColorization.enabled":false,"breadcrumbs.enabled":false,"workbench.tree.renderIndentGuides":"none","explorer.compactFolders":false},"appVersion":"2.2.1","cliVersion":"0.34.0","buildDate":"2023-08-31T13:53:43.373Z"}
Starting backend process. PID: 2651
Using browser-only version of superagent in non-browser environment
Configuration directory URI: 'file:///Users/oliveyu/.arduinoIDE'
Configuring to accept webviews on '^.+\.webview\..+$' hostname.
2023-09-13T01:15:04.808Z root INFO Backend Object.initialize: 2.3 ms [Finished 0.253 s after backend start]
2023-09-13T01:15:04.808Z root INFO Backend Object.configure: 1.9 ms [Finished 0.253 s after backend start]
2023-09-13T01:15:04.808Z root INFO Backend a.onStart: 0.8 ms [Finished 0.253 s after backend start]
2023-09-13T01:15:04.809Z root INFO Backend a.configure: 0.2 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.809Z root INFO Backend u.onStart: 0.1 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.809Z root INFO Backend d.configure: 0.0 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.810Z root INFO Backend d.initialize: 14.7 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.810Z root INFO Backend c.onStart: 0.1 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.810Z root INFO Backend s.configure: 0.4 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.811Z config INFO >>> Initializing CLI configuration...
2023-09-13T01:15:04.811Z root INFO Backend c.initialize: 0.2 ms [Finished 0.268 s after backend start]
2023-09-13T01:15:04.811Z root INFO Backend P.onStart: 0.4 ms [Finished 0.269 s after backend start]
2023-09-13T01:15:04.811Z config INFO Loading CLI configuration from /Users/oliveyu/.arduinoIDE/arduino-cli.yaml...
2023-09-13T01:15:04.811Z daemon INFO Starting daemon from /Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/resources/arduino-cli...
2023-09-13T01:15:04.811Z root INFO Backend s.initialize: 0.2 ms [Finished 0.269 s after backend start]
2023-09-13T01:15:04.811Z root INFO Backend w.onStart: 0.4 ms [Finished 0.269 s after backend start]
2023-09-13T01:15:04.811Z root INFO Backend r.configure: 0.8 ms [Finished 0.269 s after backend start]
2023-09-13T01:15:04.812Z discovery-log INFO start
2023-09-13T01:15:04.812Z discovery-log INFO start new deferred
2023-09-13T01:15:04.812Z root INFO Backend d.initialize: 0.2 ms [Finished 0.270 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend y.onStart: 0.9 ms [Finished 0.270 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend r.configure: 0.8 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend s.onStart: 0.2 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend h.configure: 0.2 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend a.configure: 0.1 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend s.configure: 0.0 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.812Z root INFO Backend l.configure: 0.0 ms [Finished 0.271 s after backend start]
2023-09-13T01:15:04.813Z root INFO Theia app listening on http://localhost:52936.
2023-09-13T01:15:04.813Z root INFO Finished starting backend application: 1.6 ms [Finished 0.273 s after backend start]
2023-09-13T01:15:04.816Z root WARN The local plugin referenced by local-dir:/Users/oliveyu/.arduinoIDE/plugins does not exist.
2023-09-13T01:15:04.816Z root WARN The local plugin referenced by local-dir:/Users/oliveyu/.arduinoIDE/extensions does not exist.
2023-09-13T01:15:04.822Z config INFO Loaded CLI configuration: {"board_manager":{"additional_urls":[]},"build_cache":{"compilations_before_purge":10,"ttl":"720h0m0s"},"daemon":{"port":"50051"},"directories":{"data":"/Users/oliveyu/Library/Arduino15","downloads":"/Users/oliveyu/Library/Arduino15/staging","user":"/Users/oliveyu/Documents/Arduino"},"library":{"enable_unsafe_install":false},"logging":{"file":"","format":"text","level":"info"},"metrics":{"addr":":9090","enabled":true},"output":{"no_color":false},"sketch":{"always_export_binaries":false},"updater":{"enable_notification":true}}
2023-09-13T01:15:04.822Z config INFO 'directories.data' and 'directories.user' are set in the CLI configuration model.
2023-09-13T01:15:04.822Z config INFO Loaded the CLI configuration.
2023-09-13T01:15:04.825Z daemon INFO time="2023-09-12T21:15:04-04:00" level=info msg="Using config file: /Users/oliveyu/.arduinoIDE/arduino-cli.yaml"
time="2023-09-12T21:15:04-04:00" level=info msg="arduino-cli version 0.34.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Executing `arduino-cli daemon`"
Daemon is now listening on 127.0.0.1:52937
{"IP":"127.0.0.1","Port":"52937"}
2023-09-13T01:15:04.826Z daemon INFO Daemon is running.
2023-09-13T01:15:04.828Z config INFO Mapped the CLI configuration: {"dataDirUri":"file:///Users/oliveyu/Library/Arduino15","sketchDirUri":"file:///Users/oliveyu/Documents/Arduino","additionalUrls":[],"network":"none","locale":"en"}
2023-09-13T01:15:04.828Z config INFO Validating the CLI configuration...
2023-09-13T01:15:04.839Z root INFO Resolve plugins list: 27.8 ms [Finished 0.298 s after backend start]
2023-09-13T01:15:04.842Z daemon INFO time="2023-09-12T21:15:04-04:00" level=info msg="Checking signature" index=/Users/oliveyu/Library/Arduino15/package_index.json signatureFile=/Users/oliveyu/Library/Arduino15/package_index.json.sig trusted=true
2023-09-13T01:15:04.847Z daemon INFO time="2023-09-12T21:15:04-04:00" level=info msg="Loading hardware from: /Users/oliveyu/Library/Arduino15/packages"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading package arduino from: /Users/oliveyu/Library/Arduino15/packages/arduino/hardware"
time="2023-09-12T21:15:04-04:00" level=info msg="Adding monitor tool" protocol=serial tool="builtin:serial-monitor"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded platform" platform="arduino:mbed_nano@4.0.2"
time="2023-09-12T21:15:04-04:00" level=info msg="Adding monitor tool" protocol=serial tool="builtin:serial-monitor"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded platform" platform="arduino:samd@1.8.13"
time="2023-09-12T21:15:04-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/arduino/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/arduino/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:CMSIS@4.5.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:CMSIS-Atmel@1.2.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:arduinoOTA@1.2.1"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:arm-none-eabi-gcc@7-2017q4"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:bossac@1.7.0-arduino3"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:bossac@1.9.1-arduino2"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:dfu-util@0.10.0-arduino1"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:openocd@0.10.0-arduino7"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:openocd@0.11.0-arduino2"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="arduino:rp2040tools@1.0.6"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading package builtin from: /Users/oliveyu/Library/Arduino15/packages/builtin"
time="2023-09-12T21:15:04-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/builtin/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/builtin/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="builtin:ctags@5.8-arduino11"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="builtin:dfu-discovery@0.1.2"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="builtin:mdns-discovery@1.0.9"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="builtin:serial-discovery@1.4.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="builtin:serial-monitor@0.13.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading package teensy from: /Users/oliveyu/Library/Arduino15/packages/teensy/hardware"
2023-09-13T01:15:04.876Z daemon INFO time="2023-09-12T21:15:04-04:00" level=info msg="Adding monitor tool" protocol=teensy tool="teensy:teensy-monitor"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded platform" platform="teensy:avr@1.58.1"
time="2023-09-12T21:15:04-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/teensy/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/teensy/tools"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="teensy:teensy-compile@11.3.1"
time="2023-09-12T21:15:04-04:00" level=info msg="Loaded tool" tool="teensy:teensy-tools@1.58.0"
time="2023-09-12T21:15:04-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/teensy/hardware/avr/1.58.1/libraries location=platform
time="2023-09-12T21:15:04-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/arduino/hardware/samd/1.8.13/libraries location=platform
time="2023-09-12T21:15:04-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/arduino/hardware/mbed_nano/4.0.2/libraries location=platform
time="2023-09-12T21:15:04-04:00" level=info msg="Loading libraries index file" index=/Users/oliveyu/Library/Arduino15/library_index.json
2023-09-13T01:15:04.877Z root ERROR Detected an error response during the gRPC core client initialization: code: 9, message: Error loading hardware platform: discovery teensy:teensy-discovery not found
2023-09-13T01:15:04.959Z daemon INFO time="2023-09-12T21:15:04-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/libraries location=ide
time="2023-09-12T21:15:04-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Documents/Arduino/libraries location=user
2023-09-13T01:15:05.249Z root INFO Deploy plugins list: 27.8 ms [Finished 0.709 s after backend start]
Opening channel for service path '/services/electron-window'.
Opening channel for service path '/services/ide-updater'.
2023-09-13T01:15:05.789Z root WARN Frontend a.configure took longer than the expected maximum 100 milliseconds: 155.9 ms [Finished 0.749 s after frontend start]
2023-09-13T01:15:05.820Z root WARN A command editor.action.toggleStickyScroll is already registered.
2023-09-13T01:15:06.788Z config INFO The CLI config is valid.
2023-09-13T01:15:06.789Z config INFO <<< Initialized the CLI configuration.
2023-09-13T01:15:06.812Z root ERROR The primary packages indexes are missing. Running indexes update before initializing the core gRPC client The index of the cores and libraries must be updated before initializing the core gRPC client.
The following problems were detected during the gRPC client initialization:
[platform-index] - code: 9, message: Error loading hardware platform: discovery teensy:teensy-discovery not found

2023-09-13T01:15:06.812Z daemon INFO time="2023-09-12T21:15:06-04:00" level=info msg="Updating index" url="https://downloads.arduino.cc/packages/package_index.tar.bz2"
2023-09-13T01:15:06.813Z daemon INFO time="2023-09-12T21:15:06-04:00" level=info msg="Starting download" url="https://downloads.arduino.cc/packages/package_index.tar.bz2"
2023-09-13T01:15:06.813Z root INFO core-client-provider [platform-index] Downloading index: package_index.tar.bz2

2023-09-13T01:15:07.232Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Checking signature" index=/Users/oliveyu/Library/Arduino15/package_index.json signatureFile=/Users/oliveyu/Library/Arduino15/package_index.json.sig trusted=true
2023-09-13T01:15:07.233Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loading hardware from: /Users/oliveyu/Library/Arduino15/packages"
2023-09-13T01:15:07.233Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loading package arduino from: /Users/oliveyu/Library/Arduino15/packages/arduino/hardware"
2023-09-13T01:15:07.233Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding monitor tool" protocol=serial tool="builtin:serial-monitor"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded platform" platform="arduino:mbed_nano@4.0.2"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding monitor tool" protocol=serial tool="builtin:serial-monitor"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded platform" platform="arduino:samd@1.8.13"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/arduino/tools"
time="2023-09-12T21:15:07-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/arduino/tools"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:CMSIS@4.5.0"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:CMSIS-Atmel@1.2.0"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:arduinoOTA@1.2.1"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:arm-none-eabi-gcc@7-2017q4"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:bossac@1.7.0-arduino3"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:bossac@1.9.1-arduino2"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:dfu-util@0.10.0-arduino1"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:openocd@0.10.0-arduino7"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:openocd@0.11.0-arduino2"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="arduino:rp2040tools@1.0.6"
time="2023-09-12T21:15:07-04:00" level=info msg="Loading package builtin from: /Users/oliveyu/Library/Arduino15/packages/builtin"
time="2023-09-12T21:15:07-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/builtin/tools"
time="2023-09-12T21:15:07-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/builtin/tools"
2023-09-13T01:15:07.234Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="builtin:ctags@5.8-arduino11"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="builtin:dfu-discovery@0.1.2"
2023-09-13T01:15:07.235Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="builtin:mdns-discovery@1.0.9"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="builtin:serial-discovery@1.4.0"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="builtin:serial-monitor@0.13.0"
2023-09-13T01:15:07.235Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loading package teensy from: /Users/oliveyu/Library/Arduino15/packages/teensy/hardware"
2023-09-13T01:15:07.237Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding monitor tool" protocol=teensy tool="teensy:teensy-monitor"
time="2023-09-12T21:15:07-04:00" level=info msg="Loaded platform" platform="teensy:avr@1.58.1"
time="2023-09-12T21:15:07-04:00" level=info msg="Checking existence of 'tools' path: /Users/oliveyu/Library/Arduino15/packages/teensy/tools"
time="2023-09-12T21:15:07-04:00" level=info msg="Loading tools from dir: /Users/oliveyu/Library/Arduino15/packages/teensy/tools"
2023-09-13T01:15:07.237Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="teensy:teensy-compile@11.3.1"
2023-09-13T01:15:07.237Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Loaded tool" tool="teensy:teensy-tools@1.58.0"
2023-09-13T01:15:07.237Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/arduino/hardware/mbed_nano/4.0.2/libraries location=platform
2023-09-13T01:15:07.237Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/arduino/hardware/samd/1.8.13/libraries location=platform
2023-09-13T01:15:07.237Z root ERROR Detected an error response during the gRPC core client initialization: code: 9, message: Error loading hardware platform: discovery teensy:teensy-discovery not found
2023-09-13T01:15:07.238Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/packages/teensy/hardware/avr/1.58.1/libraries location=platform
time="2023-09-12T21:15:07-04:00" level=info msg="Loading libraries index file" index=/Users/oliveyu/Library/Arduino15/library_index.json
2023-09-13T01:15:07.322Z daemon INFO time="2023-09-12T21:15:07-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Library/Arduino15/libraries location=ide
time="2023-09-12T21:15:07-04:00" level=info msg="Adding libraries dir" dir=/Users/oliveyu/Documents/Arduino/libraries location=user
2023-09-13T01:15:07.378Z root ERROR Uncaught Exception:  Error: The index of the cores and libraries must be updated before initializing the core gRPC client.
The following problems were detected during the gRPC client initialization:
[platform-index] - code: 9, message: Error loading hardware platform: discovery teensy:teensy-discovery not found

2023-09-13T01:15:07.378Z root ERROR Error: The index of the cores and libraries must be updated before initializing the core gRPC client.
The following problems were detected during the gRPC client initialization:
[platform-index] - code: 9, message: Error loading hardware platform: discovery teensy:teensy-discovery not found

    at /Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/main.js:2:586141
    at _.evaluateErrorStatus (/Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/main.js:2:586157)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async s.<anonymous> (/Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/main.js:2:585827)


Hi @oy312. I see the problem here:

Arduino IDE gets the list of ports of Arduino boards connected to your computer from helper tools called "pluggable discoveries".

Arduino IDE automatically installs these tools, but in this case the tool is not present at the path where it should be installed:

/Users/oliveyu/Library/Arduino15/packages/teensy/tools/teensy-discovery/1.58.0/teensy-discovery

The reason for the missing file is likely a false positive by your antivirus or security software. Please check your security software's quarantine. If you can restore the file from quarantine and then restart Arduino IDE, you should find that the ports are detected as expected.

I also recommend adjusting the configuration of your security software so that it won't interfere with any future updates of the tool.

If you are unable to restore the file from quarantine, just comment here to let me know and I'll provide some alternative instructions you can follow to force Arduino IDE to make a fresh installation of the tool.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.