Skip to content

fix(termux-native-worker): serving≠installed also sees a tar redeploy (ctime) (#2791 2a) - #2928

Merged
seoseo-ai merged 2 commits into
mainfrom
fix/2791-ctime-stale
Nov 27, 2026
Merged

seoseo-ai merged 2 commits into
mainfrom
fix/2791-ctime-stale

Conversation

@seoseo-ai

@seoseo-ai seoseo-ai commented Nov 27, 2026 •

Copy link
Copy Markdown
Collaborator

#2791 2단계 PR1(2a, 탐지 보강) — 진행안(코멘트)에서 「결정과 무관하게 착수 가능」으로 적은 부분입니다.

왜

1단계(#2794)의 serving≠installed 탐지는 파일 mtime만 프로세스 시작과 비교했습니다. tar 재배포는 빌드 시각 mtime을 그대로 두므로 놓칩니다. 실측(11-27 읽기 전용): Termux 노드 2대 모두 dist/worker.js mtime이 빌드 시각 2026-11-24 10:29:40, ctime은 배포 시각(약 3.5시간 뒤).

무엇

  • scripts/lib/a2a-native-worker-stale.sh: 비교 기준을 max(mtime, ctime)으로.
  • 여전히 경고만(재시작 없음). chmod/chown도 ctime을 바꾸므로 그 뒤에도 "바뀜"으로 보일 수 있음(경고 쪽으로 기우는 쪽).
  • 테스트: mtime을 2000-01-01로 둔 채 프로세스 시작 뒤 교체된 worker.js를 잡는지(진군 로컬 54/54, mutation 확인 — mtime만 보면 실패). shellcheck -S warning 깨끗.
  • changelog fragment.

범위 밖 (결정 대기)

PR2(재기동 도구, 기본 off)·PR3(배포 스크립트 정본화)은 #2791 결정 1~3 뒤. 노드 반영은 self-update(배포 시점 별도).

머지는 오너 승인 뒤(PR별).

🤖 Generated with Claude Code

… (ctime) (#2791 2a)

The stale report compared each process start with the file's mtime only. A tar redeploy keeps the build's mtime
(2026-11-24: dist/worker.js 10:29:40 on daegyo and gongyung, deployed 14:03 / 14:06 by ctime), so a worker still
serving the old code after such a deploy was invisible. Compare with max(mtime, ctime). Warn-only as before;
nothing restarts.

- scripts/lib/a2a-native-worker-stale.sh: max(st_mtime, st_ctime)
- health test: a worker.js with a 2000-01-01 mtime replaced after its process started is reported
  (mutation-checked: mtime-only fails it); suite 54/54, shellcheck -S warning clean
- changelog.d/2791-native-worker-stale-ctime.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@seoseo-ai
seoseo-ai requested a review from jinon86 as a code owner November 27, 2026 05:30
#1451 ratchet)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@jinon86 jinon86 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved after exact-head validation and fresh operator authorization using the relay-held jinon86 credential.

@seoseo-ai
seoseo-ai added this pull request to the merge queue Nov 27, 2026
Merged via the queue into main with commit e64c9d8 Nov 27, 2026
17 checks passed
@seoseo-ai
seoseo-ai deleted the fix/2791-ctime-stale branch November 27, 2026 06:10
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.

2 participants