4.3 KiB
Relay log — issue-62-authstorage
Append-only. One concise entry per leg. Do not read end-to-end for orientation;
use status.md. Targeted lookups only.
Leg 0 — Planning (assessment + relay packet)
Did:
- Read issue #62 and confirmed the crash: static
import { AuthStorage }fails at ESM load with Pi 0.80.8+. - Investigated all
AuthStorage/ModelRegistryusage insrc/(3 production files + 5 test/support files undersrc/server/sessions/; other pi-coding-agent imports unaffected). - Downloaded and diffed real npm tarballs (pi-coding-agent 0.80.7/0.80.8/0.80.10
and pi-ai 0.80.7/0.80.8) into
/srv/dev/pi-inspect(scratch, outside repo) to establish the exact new export surface:AuthStorageand its backends removed from exports; newModelRuntime(async) +readStoredCredential; changedModelRegistry(constructed from a runtime,refresh()now async, noauthStorage); pi-aiCredentialStore/InMemoryCredentialStore/AuthInteractionmodel. Confirmed 0.80.8 and 0.80.10.d.tsare identical for the affected files (stable target). - Wrote
ASSESSMENT-issue-62.md(root).
Decisions:
- Clean migration to
ModelRuntime, no dual-version compat shim. Rationale: sync→async, credential-store contract change, OAuth callback contract change, and session-services option change span both surfaces with no small clean adapter; 0.80.0–0.80.7 is already broken/superseded (latest= 0.80.10). - Dep range fix: peerDeps
>=0.80.0 <1→>=0.80.8 <0.81for all three@earendil-works/*packages; upper bound<0.81because this line ships breaking changes within0.80.x. - Relay packet placed under
relays/issue-62-authstorage/(committed; not inpackage.jsonfiles, so not published;.pi-web/is gitignored so not used).
Artifacts changed: ASSESSMENT-issue-62.md;
relays/issue-62-authstorage/{charter,status,log}.md.
Status update: last completed leg 0, next leg 1 = charter slice 0 (Bootstrap: install Pi 0.80.8+, correct dep ranges).
Blockers: none. Noted /tmp disk-quota issue (install in worktree) and the
pending sessiond restart for later daemon-path slices.
Handoff: Planning only — NOT auto-spawning the first implementation leg. Assessment + relay plan are laid out ready to be kicked off by the user.
Leg 1 — Slice 0 Bootstrap (deps + range correction)
Did:
- Corrected
package.json: three@earendil-works/*devDependencies^0.80.6→^0.80.8; peerDependencies>=0.80.0 <1→>=0.80.8 <0.81. npm installin the worktree. The default/tmp-based node-gyp build ofnode-ptyfailed with "Disk quota exceeded" (/tmp is a 5.8G tmpfs at ~81%). Re-ran withTMPDIR="$PWD/.tmp-build" npm install, which succeeded (618 packages, 0 vulnerabilities). Removed.tmp-buildafter.- Confirmed installed versions: all three packages resolve to 0.80.10 (lockfile updated).
- Verified the new export surface via a node ESM check:
ModelRuntime✓,readStoredCredential✓,ModelRegistry✓,AuthStorageabsent ✓, pi-aiInMemoryCredentialStore✓. - Ran
npx tsc --noEmit: 24 errors, all insrc/server/sessions/at the expected migration sites (removedAuthStorage,ModelRegistry.create/inMemory,authStorageon session-services options,PiAgentSession.modelRegistry). This matches assessment §2/§3 — the new surface resolves; only Pi Web's old usage is broken.
Decisions:
- Committed with
git commit --no-verify: the pre-commit hook runs a whole-project typecheck which cannot pass until the migration lands. Charter explicitly permits non-verify-green legs. Documented this + theTMPDIRworkaround instatus.mdso future legs don't rediscover them. - Did not touch any
src/migration code — kept strictly to slice 0 scope.
Artifacts changed: package.json, package-lock.json (commit 0fa9d0e);
relays/issue-62-authstorage/{status,log}.md. node_modules/ installed
(gitignored, not committed).
Status update: last completed leg 1, next leg 2 = charter slice 1
(authService.ts core migration → propagate async construction to sessiond.ts).
Blockers: none. Sessiond restart still pending (becomes relevant from leg 2
onward once sessiond.ts changes land).
Handoff: spawning leg 2 (slice 1).