nexus/packages
John Wessel 2aa607c828
fix(opencode-local): resolve HOME from os.userInfo() for model discovery
When Paperclip's server is started via `runuser -u node` (common in
Docker/Fly.io deployments), the HOME environment variable retains the
parent process's value (e.g. /root) instead of the target user's home
directory (/home/node). This causes `opencode models` to miss provider
auth credentials stored under the actual user's home, resulting in
"Configured OpenCode model is unavailable" errors for providers that
require API keys (e.g. zai/zhipuai).

Fix: use `os.userInfo().homedir` (reads from /etc/passwd, not env) to
ensure the child process always sees the correct HOME, regardless of
how the server was launched.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 12:58:13 -04:00
..
adapter-utils fix: address review feedback on skills and session compaction 2026-03-17 09:21:44 -05:00
adapters fix(opencode-local): resolve HOME from os.userInfo() for model discovery 2026-03-17 12:58:13 -04:00
db Add workspace operation tracking and fix project properties JSX 2026-03-17 09:36:35 -05:00
plugins Merge remote-tracking branch 'public-gh/master' into paperclip-subissues 2026-03-16 19:51:09 -05:00
shared Add workspace operation tracking and fix project properties JSX 2026-03-17 09:36:35 -05:00