2026年11月18日水曜日

Audio Plugin Coder (APC)のAPC Hubでエラー

Audio Plugin Coder (APC) GithubサイトのREADMEにある「APC Hub」で起動時にエラー
「https://github.com/Noizefield/audio-plugin-coder」

APC Hub
The APC Hub gives you a complete, live overview of the framework and your plugins - no build required, read-only by default:

node hub/server.js --port 4872 # or: /apc-hub in your agent

~/audio-plugin-coder$ node hub/server.js --port 4872

+--------------------+
| APC/HUB_ |
| hub server 1.0.4 |
+--------------------+

-> http://localhost:4872/
repo: /home/alfaalfa/audio-plugin-coder

node:events:505
throw er; // Unhandled 'error' event
^

Error: spawn xdg-open ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:315:19)
at onErrorNT (node:internal/child_process:553:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
Emitted 'error' event on ChildProcess instance at:
at ChildProcess._handle.onexit (node:internal/child_process:321:12)
at onErrorNT (node:internal/child_process:553:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
errno: -2,
code: 'ENOENT',
syscall: 'spawn xdg-open',
path: 'xdg-open',
spawnargs: [ 'http://localhost:4872/' ]
}

Node.js v26.13.1

原因はLinux環境で xdg-open を使用してブラウザを起動しようとしていて、xdg-utils がインストールされていないため ENOENT エラーになってるみたい。
多分、wsl2上のディストリビューションにインストールしたので、ブラウザなんてインストールされてないから...
対応としては「--no-open フラグを使ってブラウザの自動起動を無効にする」のが手っ取り早い感じ。
~/audio-plugin-coder$ node hub/server.js --port 4872 --no-open

+--------------------+
| APC/HUB_ |
| hub server 1.0.4 |
+--------------------+

-> http://localhost:4872/
repo: /home/alfaalfa/audio-plugin-coder

0 件のコメント: