leerness 1.9.396 → 1.9.397
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/README.md +5 -5
- package/bin/harness.js +9 -3
- package/package.json +1 -1
- package/scripts/e2e.js +16 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.9.397 — 2026-06-06 — install-safety 레시피 셸-무관화 (6번째 외부평가 P1-A, UR-0098)
|
|
4
|
+
|
|
5
|
+
**🪟 install-safety 안전설치 레시피를 셸-무관으로 — Windows PowerShell(주환경)에서 깨지던 POSIX env-prefix 제거.**
|
|
6
|
+
|
|
7
|
+
### 배경 (6번째 외부평가 codex P1-A · 비판검토 후 채택)
|
|
8
|
+
codex 가 레시피의 `npm_config_ignore_scripts=true npx ...`(bash env-prefix)가 PowerShell 에서 실패한다고 지적. **직접 검토**: PowerShell 비호환은 실문제(Windows 주환경)이나 "update 단계 ignore-scripts 누락"은 저가치(leerness 는 0 deps/0 install-script 라 실행될 스크립트 없음). → **셸 호환만 핵심 수정**.
|
|
9
|
+
|
|
10
|
+
### 구현
|
|
11
|
+
- safeInstall 레시피: `npm_config_x=true npx ...`(POSIX) → `npx --yes leerness@latest ...`(셸 무관). PowerShell/cmd/bash 모두 동작.
|
|
12
|
+
- `hardeningNote` 신규: leerness 자체 0-script 명시 + 일반 npx 하드닝(타 패키지 대비)을 셸별로 안내(bash/PowerShell/cmd). 사람용 출력에도 노출.
|
|
13
|
+
|
|
14
|
+
### 검증 (회귀 0)
|
|
15
|
+
- **selftest 142→143 PASS** (safeInstall 에 POSIX env-prefix 부재 + npx --yes 2건 + hardeningNote PowerShell 언급).
|
|
16
|
+
- **E2E 335→336 PASS** (install-safety --json 셸-무관 + hardeningNote).
|
|
17
|
+
|
|
3
18
|
## 1.9.396 — 2026-06-06 — 6번째 외부 멀티모델 리뷰 + task drop 데이터 손상 수정 (UR-0097)
|
|
4
19
|
|
|
5
20
|
**🔬 6번째 외부 클린룸 리뷰(codex GPT-5.5 + Opus) — findings 7건 등록 + 최우선 데이터 손상(task drop) 즉시 수정.**
|
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
> **AI 코딩 에이전트의 거짓 완료·중복·망각·충돌을 막아주는 검수·기억·협업 CLI 하네스.**
|
|
4
4
|
> **A CLI harness that stops AI coding agents from faking completion, duplicating work, forgetting context, and colliding.**
|
|
5
5
|
|
|
6
|
-
[](https://www.npmjs.com/package/leerness) [](https://www.npmjs.com/package/leerness) []() []() []() []() []() []()
|
|
7
7
|
|
|
8
8
|
```
|
|
9
9
|
╔══════════════════════════════════════════════════════════════╗
|
|
@@ -471,7 +471,7 @@ MIT — © leerness contributors
|
|
|
471
471
|
<!-- leerness:project-readme:start -->
|
|
472
472
|
## Leerness Project Harness
|
|
473
473
|
|
|
474
|
-
이 프로젝트는 Leerness v1.9.
|
|
474
|
+
이 프로젝트는 Leerness v1.9.397 하네스를 사용합니다. AI 에이전트는 작업 전 `leerness handoff`로 컨텍스트를 적재하고, 작업 후 `leerness check`/`leerness audit`/`leerness session close`를 수행해야 합니다.
|
|
475
475
|
|
|
476
476
|
### 정체성 — AI 에이전트 운영 레이어 (UR-0030)
|
|
477
477
|
|
|
@@ -525,7 +525,7 @@ leerness memory restore decision <date|title>
|
|
|
525
525
|
|
|
526
526
|
### MCP server (외부 AI 통합)
|
|
527
527
|
|
|
528
|
-
Leerness v1.9.
|
|
528
|
+
Leerness v1.9.397는 stdio JSON-RPC MCP server를 내장합니다 — Claude Code · Cursor · Codex CLI 등 외부 AI에 **85개 도구**를 노출:
|
|
529
529
|
|
|
530
530
|
```jsonc
|
|
531
531
|
// 카테고리별
|
|
@@ -546,7 +546,7 @@ Leerness v1.9.396는 stdio JSON-RPC MCP server를 내장합니다 — Claude Cod
|
|
|
546
546
|
`<<autonomous-loop-dynamic>>` 신호만 보내면 AI가:
|
|
547
547
|
1) 다음 라운드 후보 선정 → 2) 코드 변경 → 3) stress-v* 신규 작성 + 누적 회귀 → 4) e2e 219/219 → 5) npm pack + git tag + GitHub release → 6) main 자동 push (1.9.140+) → 7) session close → 8) 다음 라운드 예약.
|
|
548
548
|
|
|
549
|
-
현재 누적: **70 라운드 (1.9.40 → 1.9.
|
|
549
|
+
현재 누적: **70 라운드 (1.9.40 → 1.9.397)** · 매 라운드 GitHub release/태그 생성 · _reports/는 비공개 보존.
|
|
550
550
|
|
|
551
551
|
### 성능 가이드 (1.9.140 측정)
|
|
552
552
|
|
|
@@ -584,6 +584,6 @@ leerness release pack --close --auto-main-push
|
|
|
584
584
|
- `.harness/session-handoff.md`: 다음 세션 인수인계 (자동 작성)
|
|
585
585
|
- `.harness/lessons.md` / `decisions.md` / `rules.md`: 영구 메모리 (5 surface)
|
|
586
586
|
|
|
587
|
-
Last synced by Leerness v1.9.
|
|
587
|
+
Last synced by Leerness v1.9.397: 2026-06-06
|
|
588
588
|
<!-- leerness:project-readme:end -->
|
|
589
589
|
|
package/bin/harness.js
CHANGED
|
@@ -31,7 +31,7 @@ const { _evidenceQuality, _parseEvidenceStats, _shellGuardAnalyze, _claimFileInG
|
|
|
31
31
|
// 1.9.295 (UR-0025 4단계): 정적 데이터 카탈로그 모듈 분리 (비파괴, require-based).
|
|
32
32
|
const { CAPABILITY_SURFACE, POWERFUL_COMMANDS, ADAPTERS, REUSE_CATEGORIES, REUSE_CHECKLIST, _DEFAULT_PLATFORM_CONSTRAINTS, _DEFAULT_DOMAIN_CATALOG, _LSP_LANG_PATTERNS, OPTIMISM_PATTERNS, BUILT_IN_PERSONAS, STRINGS, BUILTIN_CATALOG, ROADMAP_STATUS_LABEL, ROADMAP_STATUS_COLOR, SECRET_PATTERNS, MERGE_OVERWRITE_FILES, MINIMAL_SKIP_KEYS, REQUIRED_WORKSPACE_FILES, KEYWORD_STOPWORDS, SKILL_CATALOG_PRESETS } = require('../lib/catalogs'); // 1.9.344/368/369 (UR-0025): catalog 분리 (MERGE_OVERWRITE_FILES/MINIMAL_SKIP_KEYS 포함)
|
|
33
33
|
|
|
34
|
-
const VERSION = '1.9.
|
|
34
|
+
const VERSION = '1.9.397';
|
|
35
35
|
|
|
36
36
|
// 1.9.290 (UR-0037, Codex gpt-5.5 #4 수렴): CLI 전용 부작용은 require 시 실행하지 않는다.
|
|
37
37
|
// 이전: warning listener 제거 / NODE_OPTIONS 변경 / chcp IIFE 가 top-level 즉시 실행 → require('harness') 시 호스트 프로세스 오염.
|
|
@@ -3001,6 +3001,7 @@ function _selfTestCases() {
|
|
|
3001
3001
|
{ name: 'UR-0025 whats-new 완결: whatsNewCmd → lib/diagnostics.js + DI 위임 + 동작 (1.9.394)', run: () => { const m = require('../lib/diagnostics'); const expOk = typeof m.whatsNewCmd === 'function'; const src = read(__filename); const delegated = src.includes('_diag.whatsNewCmd(root,'); const diagSrc = read(path.join(path.dirname(__filename), '..', 'lib', 'diagnostics.js')); const movedToLib = diagSrc.includes('leerness whats-new') && diagSrc.includes('_parseChangelogBetween'); let behavOk = false; const tmp = fs.mkdtempSync(path.join(os.tmpdir(), '__leerness_wn_')); const save = process.argv; const _w = process.stdout.write; let out = ''; try { fs.mkdirSync(path.join(tmp, '.harness'), { recursive: true }); fs.writeFileSync(path.join(tmp, 'CHANGELOG.md'), '## 1.9.50 — 2026-06-06 — A\n- `leerness x`\n\n## 1.9.49 — 2026-06-05 — B\n- old\n'); process.argv = ['node', 'h', 'whats-new', tmp, '--from', '1.9.49', '--to', '1.9.50', '--json']; process.stdout.write = s => { out += s; return true; }; whatsNewCmd(tmp); } catch {} finally { process.stdout.write = _w; process.argv = save; try { fs.rmSync(tmp, { recursive: true, force: true }); } catch {} } try { const j = JSON.parse(out); behavOk = j.from === '1.9.49' && j.to === '1.9.50' && Array.isArray(j.versions) && j.versions.length === 1 && j.versions[0].version === '1.9.50'; } catch {} return expOk && delegated && movedToLib && behavOk; } },
|
|
3002
3002
|
{ name: '회귀가드: decisions/lessons canonical round-trip 엣지문자(pipe/dash/colon) 무손상 + idempotent (1.9.395)', run: () => { const m = require('../lib/pure-utils'); const d = [{ date: '2026-06-06', title: 'A | pipe', decision: 'use X | Y', reason: 'r—dash', alternatives: 'alt: colon', impact: 'i' }]; const dback = m._decisionsFromMd(m._renderDecisionsMd(d)); const dOk = dback.length === 1 && dback[0].title === 'A | pipe' && dback[0].decision === 'use X | Y' && dback[0].reason === 'r—dash'; const dIdem = JSON.stringify(dback) === JSON.stringify(m._decisionsFromMd(m._renderDecisionsMd(dback))); const l = [{ date: '2026-06-06', text: 'lesson | with — chars: ok', tag: 't' }]; const lback = m._parseLessonEntries(m._renderLessonsMd(l)); const lOk = lback.length === 1 && lback[0].text === 'lesson | with — chars: ok'; const lIdem = JSON.stringify(lback) === JSON.stringify(m._parseLessonEntries(m._renderLessonsMd(lback))); return dOk && dIdem && lOk && lIdem; } },
|
|
3003
3003
|
{ name: '6번째 외부평가/codex P1-B: task drop 존재확인 가드 — 없는 ID 가짜 row 방지 (1.9.396)', run: () => { const src = read(__filename); const i = src.indexOf('function taskDrop(root, id)'); if (i < 0) return false; const body = src.slice(i, i + 700); return body.includes('not found in progress-tracker.md') && body.includes('rows.find(r => r.id === id)') && body.includes('_requireInit'); } },
|
|
3004
|
+
{ name: '6번째 외부평가/codex P1-A (UR-0098): install-safety 레시피 셸-무관 + hardeningNote (1.9.397)', run: () => { if (typeof installSafetyCmd !== 'function') return false; const save = process.argv; const _w = process.stdout.write; let out = ''; try { process.argv = ['node', 'h', 'install-safety', '--json']; process.stdout.write = s => { out += s; return true; }; installSafetyCmd({ json: true }); } catch {} finally { process.stdout.write = _w; process.argv = save; } let j; try { j = JSON.parse(out); } catch {} const noPosixPrefix = !!j && Array.isArray(j.safeInstall) && !j.safeInstall.some(x => /^npm_config_\w+=/.test(String(x).trim())); const crossShell = !!j && j.safeInstall.filter(x => String(x).includes('npx --yes')).length >= 2; const noteOk = !!j && typeof j.hardeningNote === 'string' && j.hardeningNote.includes('PowerShell'); return noPosixPrefix && crossShell && noteOk; } },
|
|
3004
3005
|
{ name: 'VERSION 형식 (x.y.z)', run: () => /^\d+\.\d+\.\d+$/.test(VERSION) }
|
|
3005
3006
|
];
|
|
3006
3007
|
}
|
|
@@ -6710,12 +6711,16 @@ function installSafetyCmd(opts = {}) {
|
|
|
6710
6711
|
hasInstallScripts: installHooks.length > 0,
|
|
6711
6712
|
node: (pkg.engines && pkg.engines.node) || null,
|
|
6712
6713
|
offlineFirst: true,
|
|
6714
|
+
// 1.9.397 (6번째 외부평가/codex P1-A, UR-0098): 레시피를 셸-무관으로 — 종전 'npm_config_x=true npx'(POSIX env-prefix)는
|
|
6715
|
+
// PowerShell(Windows 주환경)에서 실패. leerness 는 0 deps/0 install-script 라 npx 시 실행될 스크립트 자체가 없어 prefix 불필요.
|
|
6716
|
+
// 타 패키지 대비 일반 하드닝은 셸별로 hardeningNote 참조.
|
|
6713
6717
|
safeInstall: [
|
|
6714
6718
|
'git checkout -b chore/leerness-update',
|
|
6715
|
-
'
|
|
6716
|
-
'npx leerness@latest update --yes --path .',
|
|
6719
|
+
'npx --yes leerness@latest migrate plan --path . # 임시폴더 비교(읽기 전용, 셸 무관)',
|
|
6720
|
+
'npx --yes leerness@latest update --yes --path .',
|
|
6717
6721
|
'git diff # 변경 검토 후 커밋 또는 롤백',
|
|
6718
6722
|
],
|
|
6723
|
+
hardeningNote: 'leerness 자체는 0 deps / 0 install-script 라 설치/업데이트 시 임의코드 실행 없음. 일반 npx 하드닝(타 패키지 대비)은 셸별 — bash: npm_config_ignore_scripts=true npx ... · PowerShell: $env:npm_config_ignore_scripts=1; npx ... · cmd: set npm_config_ignore_scripts=1 && npx ...',
|
|
6719
6724
|
};
|
|
6720
6725
|
if (opts.json) { log(JSON.stringify(profile, null, 2)); return; }
|
|
6721
6726
|
log(`# leerness install-safety (1.9.359) — 설치 안전 프로필`);
|
|
@@ -6725,6 +6730,7 @@ function installSafetyCmd(opts = {}) {
|
|
|
6725
6730
|
log(` 동작 방식: offline-first (설치 시 네트워크/빌드 불필요, 단일 bin + lib)`);
|
|
6726
6731
|
log(`\n 안전 설치 워크플로 (검토 후 적용):`);
|
|
6727
6732
|
profile.safeInstall.forEach((s, i) => log(` ${i + 1}. ${s}`));
|
|
6733
|
+
log(`\n ⓘ ${profile.hardeningNote}`); // 1.9.397 (UR-0098): 셸별 하드닝 노트
|
|
6728
6734
|
if (installHooks.length > 0) warn('install-time 스크립트 존재 — 위 ignore-scripts safe-install 권장');
|
|
6729
6735
|
}
|
|
6730
6736
|
function debug(root) {
|
package/package.json
CHANGED
package/scripts/e2e.js
CHANGED
|
@@ -5521,5 +5521,21 @@ total++;
|
|
|
5521
5521
|
if (!ok) failed++;
|
|
5522
5522
|
}
|
|
5523
5523
|
|
|
5524
|
+
// 1.9.397 회귀 (6번째 외부평가/codex P1-A, UR-0098): install-safety 레시피 셸-무관(POSIX env-prefix 제거) + hardeningNote
|
|
5525
|
+
total++;
|
|
5526
|
+
{
|
|
5527
|
+
let ok = false;
|
|
5528
|
+
try {
|
|
5529
|
+
const r = cp.spawnSync(process.execPath, [CLI, 'install-safety', '--json'], { encoding: 'utf8', timeout: 10000 });
|
|
5530
|
+
const j = JSON.parse(r.stdout);
|
|
5531
|
+
const noPosix = Array.isArray(j.safeInstall) && !j.safeInstall.some(x => /^npm_config_\w+=/.test(String(x).trim())); // PowerShell 비호환 prefix 부재
|
|
5532
|
+
const crossShell = j.safeInstall.filter(x => String(x).includes('npx --yes')).length >= 2;
|
|
5533
|
+
const note = typeof j.hardeningNote === 'string' && j.hardeningNote.includes('PowerShell');
|
|
5534
|
+
ok = noPosix && crossShell && note;
|
|
5535
|
+
} catch {}
|
|
5536
|
+
console.log(ok ? '✓ B(1.9.397) 6th외부평가 codex P1-A: install-safety 레시피 셸-무관 + hardeningNote (UR-0098)' : '✗ install-safety 셸호환 실패');
|
|
5537
|
+
if (!ok) failed++;
|
|
5538
|
+
}
|
|
5539
|
+
|
|
5524
5540
|
console.log(`\nE2E result: ${total - failed}/${total} passed · ${((Date.now() - _e2eStart) / 1000).toFixed(0)}s`);
|
|
5525
5541
|
if (failed > 0) process.exit(1);
|