[SOLVED] IDE Not Opening on MacOS

When I click the icon to start Arduino IDE, literally nothing pops up. No window, not even an error message. The icon just shows up on the dock, bounces a few times, then nothing. Here is a video:

Here is what happens when I open it from the terminal:

Last login: Thu Oct 12 18:36:44 on console
XXXXXXXX@wireless-10-145-44-214 ~ % "/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-31T14:26:39.874Z" (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-31T14:26:39.874Z"}
Starting backend process. PID: 877
Using browser-only version of superagent in non-browser environment
Configuration directory URI: 'file:///Users/XXXXXXXX/.arduinoIDE'
Configuring to accept webviews on '^.+\.webview\..+$' hostname.
2023-10-12T23:46:25.583Z root INFO Backend Object.initialize: 6.9 ms [Finished 0.668 s after backend start]
2023-10-12T23:46:25.586Z root INFO Backend Object.configure: 5.8 ms [Finished 0.668 s after backend start]
2023-10-12T23:46:25.586Z root INFO Backend a.onStart: 2.1 ms [Finished 0.668 s after backend start]
2023-10-12T23:46:25.587Z root INFO Backend a.configure: 0.5 ms [Finished 0.706 s after backend start]
2023-10-12T23:46:25.588Z root INFO Backend u.onStart: 0.4 ms [Finished 0.706 s after backend start]
2023-10-12T23:46:25.590Z root INFO Backend d.configure: 0.2 ms [Finished 0.707 s after backend start]
2023-10-12T23:46:25.590Z root INFO Backend d.initialize: 38.5 ms [Finished 0.707 s after backend start]
2023-10-12T23:46:25.591Z root INFO Backend c.onStart: 0.4 ms [Finished 0.707 s after backend start]
2023-10-12T23:46:25.591Z root INFO Backend s.configure: 4.6 ms [Finished 0.712 s after backend start]
2023-10-12T23:46:25.593Z config INFO >>> Initializing CLI configuration...
2023-10-12T23:46:25.593Z root INFO Backend c.initialize: 0.7 ms [Finished 0.712 s after backend start]
2023-10-12T23:46:25.594Z root INFO Backend P.onStart: 1.1 ms [Finished 0.713 s after backend start]
2023-10-12T23:46:25.595Z config INFO Loading CLI configuration from /Users/XXXXXXX/.arduinoIDE/arduino-cli.yaml...
2023-10-12T23:46:25.595Z daemon INFO Starting daemon from /Applications/Arduino IDE.app/Contents/Resources/app/lib/backend/resources/arduino-cli...
2023-10-12T23:46:25.596Z root INFO Backend s.initialize: 0.5 ms [Finished 0.714 s after backend start]
2023-10-12T23:46:25.596Z root INFO Backend w.onStart: 1.4 ms [Finished 0.715 s after backend start]
2023-10-12T23:46:25.596Z root INFO Backend r.configure: 2.5 ms [Finished 0.715 s after backend start]
2023-10-12T23:46:25.596Z discovery-log INFO start
2023-10-12T23:46:25.596Z discovery-log INFO start new deferred
2023-10-12T23:46:25.596Z root INFO Backend d.initialize: 0.5 ms [Finished 0.716 s after backend start]
2023-10-12T23:46:25.596Z root INFO Backend y.onStart: 2.4 ms [Finished 0.718 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend r.configure: 2.2 ms [Finished 0.719 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend s.onStart: 0.7 ms [Finished 0.720 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend h.configure: 0.8 ms [Finished 0.720 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend a.configure: 0.4 ms [Finished 0.721 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend s.configure: 0.1 ms [Finished 0.721 s after backend start]
2023-10-12T23:46:25.597Z root INFO Backend l.configure: 0.1 ms [Finished 0.722 s after backend start]
2023-10-12T23:46:25.599Z root ERROR Failed to start the backend application:
2023-10-12T23:46:25.599Z root ERROR Error: getaddrinfo ENOTFOUND localhost
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:107:26)
2023-10-12T23:46:25.599Z root ERROR Uncaught Exception:  Error: getaddrinfo ENOTFOUND localhost
2023-10-12T23:46:25.600Z root ERROR Error: getaddrinfo ENOTFOUND localhost
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:107:26)

I have a MacOS Big Sur v11.17. It has an intel core, and so I got the MacOS intel version of the IDE. I have tried deleting and reinstalling. I have restarted my laptop. Nothing has worked. I don't know what is happening.

Hi @signgirlevil

Arduino IDE communicates with some of its helper tools via an internal TCP/IP port in your computer on "localhost". From the error message in the logs, it appears there is something unusual about your system that makes that not possible.

Have you made any modifications, or is there anything notable about your "hosts file", especially in regards to the definition of localhost?

The "hosts file" is located at /etc/hosts (AKA /private/etc/hosts).

Thank you! It appears my host file was simply a blank text file. I am not one to mess around with my computer's system files, so I don't know why this file would have been changed. Regardless I was able to find what its contents should be and restore it.

Now the IDE is at least opening a window, although it appears to be stuck on the initial loading screen indefinitely. I had to use a keyboard interrupt in the terminal when using that method to figure out the issue. Was able to resolve with this help of this thread.

Now the IDE opens and I can edit code. Thank goodness! And thank you for all your help!

You are welcome. I'm glad it is working now. Thanks for taking the time to post an update!

Regards,
Per

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