Skip to content

Fix Electron app path

Currently many features in the IDE (e.g. menu bar, clicking on links) don't work and instead cause errors to be logged to stdout:

2024-04-17T19:33:26.088Z root INFO Finished starting backend application: 1.5 ms [Finished 0.425 s after backend start]
Error: App version is not a valid semver version: "0.0"
    at t.newError (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:63605)
    at new v (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:73215)
    at new n (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:81847)
    at new p (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:70215)
    at Object.get [as autoUpdater] (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:112930)
    at new u (/usr/lib/arduino-ide/lib/backend/electron-main.js:2:56794)
    at Ee (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:616577)
    at /usr/lib/arduino-ide/lib/backend/electron-main.js:8:620554
    at Le (/usr/lib/arduino-ide/lib/backend/electron-main.js:8:620623)
    at /usr/lib/arduino-ide/lib/backend/electron-main.js:8:621010 {
  code: 'ERR_UPDATER_INVALID_VERSION'
}
WebContents #1 called ipcRenderer.sendSync() with 'GetSecurityToken' channel without listeners.
2024-04-17T19:33:26.730Z root INFO Deploy plugins list: 41.6 ms [Finished 1.067 s after backend start]
Error occurred in handler for 'GetTitleStyleAtStartup': Error: No handler registered for 'GetTitleStyleAtStartup'
    at WebContents.<anonymous> (node:electron/js2c/browser_init:2:79778)
    at WebContents.emit (node:events:514:28)
2024-04-17T19:33:56.459Z root WARN Frontend a.configure took longer than the expected maximum 100 milliseconds: 200.6 ms [Finished 30.312 s after frontend start]
2024-04-17T19:33:56.459Z root WARN A command editor.action.toggleStickyScroll is already registered.
Error occurred in handler for 'GetTitleStyleAtStartup': Error: No handler registered for 'GetTitleStyleAtStartup'
    at WebContents.<anonymous> (node:electron/js2c/browser_init:2:79778)
    at WebContents.emit (node:events:514:28)

Fix this by changing the Electron app path in arduino-ide.sh from /usr/lib/arduino-ide/arduino-ide-electron-main.js to just /usr/lib/arduino-ide. This directory matches the resources/app directory in the upstream builds, which is what should be specified as the app path according to https://wiki.archlinux.org/title/Electron_package_guidelines#Using_the_system_electron. Compare the result of running arduino-ide with electron27 /usr/lib/arduino-ide.

Edited by August Wikerfors

Merge request reports

Loading