hapi
hapi copied to clipboard
[bug]安装后操作无反应
What version of HAPI is running?
latest
What platform is your computer?
Ubuntu 24
What issue are you seeing?
运行无反应,具体执行操作如下:
node -v v25.6.0
root@racknerd-xxx:~# npm install -g @twsxtd/hapi
changed 2 packages in 6s
root@racknerd-xxx:~# ll
total 53368
drwx------ 12 root root 4096 Feb 4 03:42 ./
drwxr-xr-x 25 root root 4096 Jan 25 11:31 ../
-rw------- 1 root root 8173 Feb 4 03:43 .bash_history
-rw-r--r-- 1 root root 3338 Jan 24 11:58 .bashrc
drwx------ 2 root root 4096 May 29 2024 .cache/
drwxr-xr-x 6 root root 4096 Feb 4 03:42 .claude/
drwxr-xr-x 3 root root 4096 Jan 24 11:37 .config/
drwxr-xr-x 4 root root 4096 Feb 4 03:42 .happy/
-rw------- 1 root root 20 Jan 19 14:38 .lesshst
drwxr-xr-x 4 root root 4096 Jan 24 11:57 .local/
drwxr-xr-x 4 root root 4096 Feb 4 03:04 .npm/
drwxr-xr-x 8 root root 4096 Jan 20 06:08 .nvm/
-rw-r--r-- 1 root root 161 Apr 22 2024 .profile
-rw-r--r-- 1 root root 13067 Jan 19 14:06 shd
drwx------ 2 root root 4096 Jan 25 11:31 .ssh/
-rw------- 1 root root 12070 Feb 4 03:11 .viminfo
-rw-r--r-- 1 root root 547 May 29 2024 virt-sysprep-firstboot.log
root@racknerd-xxx:~# hapi hub --relay
root@racknerd-xxx:~#
未创建hapi文件夹 运行hapi相关命令无反应
What steps can reproduce the bug?
无
What is the expected behavior?
No response
Additional information
No response
hapi hub 启动逻辑:CLI 直接加载 hub 入口;入口启动会立刻打印 HAPI Hub starting... 等日志。--relay 由 hub 入口解析。默认数据目录是 ~/.hapi(可用 HAPI_HOME 覆盖),启动时会创建目录并写入配置。你截图里的 .happy/ 不是 HAPI 目录(代码里是 .hapi)。
Relevant code:
cli/src/commands/hub.ts:23-hapi hub入口,设置 WEBAPP_HOST/PORT 后 import hubhub/src/index.ts:108- 启动日志与--relay解析hub/src/configuration.ts:123- 默认数据目录~/.hapi,启动时创建cli/src/configuration.ts:39- CLI 侧同样默认~/.hapi
Need more info:
hapi hub --relay实际终端输出(含错误)ls -la ~/.hapi结果hapi --version输出
HAPI Bot
root@racknerd-xxx:~# hapi hub --relay
root@racknerd-xxx:~# ls -la ~/.hapi
ls: cannot access '/root/.hapi': No such file or directory
root@racknerd-xxx:~# hapi --version
root@racknerd-xxx:~#
你的 CPU 可能需要用 -baseline 编译,建议你自行编译:https://bun.com/docs/bundler/executables#supported-targets