ACP session/new rejects Berd default cwd "~" as non-absolute

Open Beginner friendly
#326 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
88/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
api, desktop

Research direction

Start in src/shared/api/acpCwd.ts at toAcpAbsoluteCwd and trace its use from newSession, loadSession, forkSession, and updateWorkingDir. Run the listed Vitest files, then verify local cwd values such as ~, ~/…, empty, and . are absolute on the ACP wire while SSH retains its remote-home spelling.

Written by the indexing model from the issue text.

Description

Summary

After the Goose ACP pin that added validate_absolute_cwd, Berd's default working directory (~, and also ~/…, empty, and .) fails session/new / session/load / fork with:

cwd must be an absolute path

That blocks every local persona from starting a session, so they never reach the CLI.

ACP (Goose, Buzz agent, MindPi, etc.) requires a POSIX-absolute path. ~ is not one.

Expected

Local ACP cwd is $HOME (or $HOME/…) on the wire. SSH backends keep the host spelling of ~ (remote home).

Local fix (not yet PR'd)

Expand at the ACP client wire in toAcpAbsoluteCwd (src/shared/api/acpCwd.ts), used by newSession, loadSession, forkSession, and updateWorkingDir.

Proof: pnpm vitest run src/shared/lib/homePath.test.ts src/shared/api/acpCwd.test.ts src/shared/api/__tests__/acpApi.test.ts src/shared/api/__tests__/acp.test.ts — 92 passed.

Residual

SSH backends still send ~. Remote Goose after the same pin will still 422 until the remote process expands home.

Dominant language
TypeScript
Stars
928
Forks
121
Avg merge
1d 8h
Merged PRs (30d)
100

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from block/berd

All issues in block/berd

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.