Skip to content

feat(update): JAM 1.5.0 — move the registration to the published release without redoing setup - #36

Merged
colosair merged 1 commit into
mainfrom
feat/jam-update
Sep 6, 2026
Merged

colosair merged 1 commit into
mainfrom
feat/jam-update

Conversation

@colosair

@colosair colosair commented Sep 6, 2026

Copy link
Copy Markdown
Owner

요약

jam update 하나를 싣는다. JAM 에서 낡는 것은 디렉터리가 아니라 줄이다 — host 는 exact pin 을 담은 등록 줄로 JAM 을 띄우므로, registry 에 새 JAM 이 올라와도 그 pin 이 움직이기 전에는 아무 것도 달라지지 않는다. 1.4.6 게시 직후 이 기계의 실측이 registration: HOST_REGISTRATION_STALE (registered 1.4.5) 였고, 그것을 고친 명령이 jam setup --agent 였다. 그 명령은 project binding·자격·나머지 전부를 다시 계획하는 다른 행위다.

updater 가 다루는 축은 정확히 둘이다: package version, host registration version. projects.yaml·project binding·자격·runtime mode·Jira 데이터는 건드리지 않는다.

변경 사항

  • packages/server/src/cli/update.ts (신규)
    • planJamUpdate — 순수 판정. CURRENT / UPDATE_AVAILABLE / BROKEN / UNKNOWN. registry 를 못 물으면 UNKNOWN 이며 절대 CURRENT 가 아니다. jam 항목이 없는 host 는 그대로 둔다 — 없던 자리에 등록하는 것은 채택이고 그것은 jam setup 의 몫이다. 버전을 읽을 수 없는 항목은 BROKEN 이다(측정되지 않은 무언가를 돌리는 줄을 "최신" 이라고 적지 않는다).
    • 실행 순서 install → verify-install → switch-registration → verify-health. 삭제가 먼저 오지 않는다 — 새 build 가 답한다는 것을 확인한 뒤에야 등록을 그쪽으로 돌린다. 실패하면 기계는 돌던 것을 그대로 돌린다.
    • 재등록은 remove 다음 add 다. Claude Code 의 mcp add 는 기존 항목 위에서 "already exists" 라고 답하고 아무 것도 바꾸지 않는다 — 이것이 stale pin 이 setup 재실행을 견뎠던 이유다.
    • 마지막은 등록물 재조회 + doctor(config·자격·live read 1회). 등록이 성공했는데 건강하지 않으면 이전 pin 으로 되돌린다.
  • packages/server/src/bootstrap/host-mcp.ts — hostRegistration 이 version 을 받는다. 지금 도는 build 가 아닌 릴리스를 등록해야 update 가 성립한다. pin 만 움직이고 나머지 argv 는 setup 이 쓰는 줄 그대로라 두 경로가 서로 다른 등록으로 갈라지지 않는다.
  • cli-entry.ts — case "update" + USAGE. @jam-mcp/bootstrap 이 다른 명령과 똑같이 그대로 forward 한다.
  • AGENTS.md · CLAUDE.md — 갱신은 setup --agent 가 아니라 jam update 라는 것, UNKNOWN 이 "최신" 이 아니라는 것, JAM 은 JAM 만 갱신한다는 것.
  • 릴리스 1.5.0 — docs/releases/v1.5.0.md, 버전 핀, lockfile.

테스트 / 검증

  • npm run release:verify (build + test + release:check + pack + tarball smoke) 전부 통과
  • 508 tests, 0 fail (update 10건 신규)
  • npx --yes @jam-mcp/[email protected] doctor --json 실기계 실행 — status: "ready" 로 doctorVerdict 파싱 형태 확인
  • published acceptance 는 게시 후 — 1.4.6 등록을 둔 채 jam update 로 1.5.0 수렴, project binding·자격 동일, doctor ready, live Jira read PASS.

신규 회귀: check 는 아무 명령도 돌리지 않는다 / 답하지 않는 pin 은 절대 등록되지 않는다(remove·add 둘 다 0회) / remove 가 add 보다 앞선다 / 등록 후 재조회가 성공 판정의 근거다 / doctor 가 ready 가 아니면 이전 pin 으로 되돌린다 / setup 이 한 번도 불리지 않는다.

리뷰 포인트

  1. hostRegistration({ version }) 의 경계. pin 문자열만 치환한다. 다른 인자를 update 가 따로 만들면 setup 이 쓰는 줄과 갈라지고, 그 갈라짐은 다음 stale 판정에서야 드러난다.
  2. bare 전역 등록. jam serve 로 등록된 기계는 pin 이 줄에 없으므로 전역 설치본이 움직여야 한다 — npm install -g 로 옮기고 등록 줄은 그대로 둔다. 이 경우 rollback 은 재설치라서, 되돌릴 수 없다고 말하고 jam setup --agent 를 안내한다.
  3. doctor 를 검증에 쓴 것. 새 health 판정을 만들지 않고 이미 있는 축을 물었다. 등록만 서고 Jira 를 못 읽는 상태를 "완료" 로 적지 않기 위해서다.

미결 / 후속

  • downgrade·특정 버전 고정 미구현.
  • Live issue.create 는 1.4.6 과 같은 이유로 여전히 미검증.
  • ASC 와 lifecycle 은 끝까지 분리한다 — jam update 가 asc update 를 부르지 않고 그 반대도 없다. 자연어 orchestration 은 agent 규약이 담당한다.

🤖 Generated with Claude Code

…redoing setup

What goes stale in JAM is a line, not a directory. The host launches JAM from a
registration carrying an exact pin, so a newer JAM on the registry changes
nothing until that pin moves. Right after 1.4.6 was published this machine
measured `registration: HOST_REGISTRATION_STALE (registered 1.4.5)`, and the
command that fixed it was `jam setup --agent` — which also re-plans the project
binding, credentials and everything else.

`jam update` moves the two axes it owns, package and registration, and nothing
else. The published build is proven to answer before the registration is pointed
at it, so a failure leaves the machine running what it was running.

- cli/update.ts — planJamUpdate is pure: CURRENT / UPDATE_AVAILABLE / BROKEN /
  UNKNOWN. A host with no jam entry is left alone (registering it there is
  adoption, which is setup's job). An entry whose version cannot be read is not
  reported as current. Apply verifies, re-pins (remove then add — `mcp add` over
  an existing entry changes nothing on Claude Code), reads the registration back
  and finishes with `doctor`, rolling back to the previous pin if that is not
  ready.
- bootstrap/host-mcp.ts — hostRegistration takes a version, so an update can
  register a release this build is not. Only the pin moves; the rest of the argv
  is the line setup writes.
- cli-entry.ts — `update`, forwarded by @jam-mcp/bootstrap like every other
  command.
- Release 1.5.0: notes and version pins.

Co-Authored-By: Claude Opus 5 <[email protected]>
@colosair
colosair merged commit f4c418c into main Sep 6, 2026
5 checks passed
@colosair
colosair deleted the feat/jam-update branch September 6, 2026 09:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant