@asc-agent/runtime 0.5.1 → 0.5.2

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/README.md CHANGED
@@ -7,7 +7,7 @@ proceed-by-default, escalation, audit, the external-write guard, host integratio
7
7
  here.
8
8
 
9
9
  ```bash
10
- npm install -g @asc-agent/runtime@0.5.1
10
+ npm install -g @asc-agent/runtime@0.5.2
11
11
  ```
12
12
 
13
13
  npm owns the executable link (on Windows, npm's own `asc.cmd`). This package never edits
package/dist/cli/asc.d.ts CHANGED
@@ -12,4 +12,6 @@ export type AscEntry = 'runtime' | 'bootstrap';
12
12
  * 사용자가 실행하는 명령이 된다 (0.2.0 회차의 skill.ts가 그랬다).
13
13
  */
14
14
  export { BOOTSTRAP_SPEC } from '../core/distribution/release.ts';
15
+ /** 재실행을 가로질러 진입점을 나르는 자리. 값은 `bootstrap` 하나뿐이다. */
16
+ export declare const ENTRY_ENV = "ASC_ENTRY";
15
17
  export declare function runAscCommand(argv: string[], entry?: AscEntry): Promise<number>;
package/dist/cli/asc.js CHANGED
@@ -515,7 +515,12 @@ function reportNodeRuntime(check, asJson) {
515
515
  for (const action of actions)
516
516
  console.error(` ${action.node.version} at ${action.node.path}\n ${action.display}`);
517
517
  }
518
+ /** 재실행을 가로질러 진입점을 나르는 자리. 값은 `bootstrap` 하나뿐이다. */
519
+ export const ENTRY_ENV = 'ASC_ENTRY';
518
520
  export async function runAscCommand(argv, entry = 'runtime') {
521
+ // 호환 Node 로 다시 실행된 프로세스는 자기가 어느 문으로 들어왔는지 argv 로는 알 수 없다.
522
+ const inherited = process.env[ENTRY_ENV] === 'bootstrap' ? 'bootstrap' : undefined;
523
+ entry = inherited ?? entry;
519
524
  let parsed;
520
525
  try {
521
526
  parsed = parseArgsOrThrow(argv);
@@ -675,7 +680,11 @@ async function runParsedCommand(values, positionals, entry, argv) {
675
680
  if (!runnable.ok) {
676
681
  // 후보를 이미 찾았으면 처방 대신 실행한다 — 같은 명령, 같은 argv, 호환 Node (A6).
677
682
  const reexec = reexecWithCandidate(runnable, argv, {
678
- env: process.env,
683
+ // **어느 문으로 들어왔는지가 재실행을 넘어가야 한다.** 이것이 없으면 bootstrap 으로
684
+ // 시작한 첫 설치가 재실행 뒤 자기를 설치된 runtime 이라고 말하고, 그러면 stable
685
+ // runtime 설치도 기계 등록도 계획에 들지 않는다 — 기본 Node 가 하한보다 낮은 기계에서
686
+ // 첫 설치가 조용히 절반만 끝나던 자리다.
687
+ env: { ...process.env, [ENTRY_ENV]: entry },
679
688
  entry: fileURLToPath(import.meta.url),
680
689
  spawn: (path, args, env) => {
681
690
  const child = spawnSync(path, args, { stdio: 'inherit', env: env });
@@ -1,9 +1,9 @@
1
1
  export declare const RUNTIME_PACKAGE = "@asc-agent/runtime";
2
2
  export declare const BOOTSTRAP_PACKAGE = "@asc-agent/bootstrap";
3
3
  /** runtime과 bootstrap은 초기 release에서 lockstep이다. */
4
- export declare const RELEASE_VERSION = "0.5.1";
5
- export declare const RUNTIME_SPEC = "@asc-agent/runtime@0.5.1";
6
- export declare const BOOTSTRAP_SPEC = "@asc-agent/bootstrap@0.5.1";
4
+ export declare const RELEASE_VERSION = "0.5.2";
5
+ export declare const RUNTIME_SPEC = "@asc-agent/runtime@0.5.2";
6
+ export declare const BOOTSTRAP_SPEC = "@asc-agent/bootstrap@0.5.2";
7
7
  /**
8
8
  * 아직 설치되지 않은 machine에서 그대로 실행되는 형태 (C-14 §3.4).
9
9
  *
@@ -9,7 +9,7 @@
9
9
  export const RUNTIME_PACKAGE = '@asc-agent/runtime';
10
10
  export const BOOTSTRAP_PACKAGE = '@asc-agent/bootstrap';
11
11
  /** runtime과 bootstrap은 초기 release에서 lockstep이다. */
12
- export const RELEASE_VERSION = '0.5.1';
12
+ export const RELEASE_VERSION = '0.5.2';
13
13
  export const RUNTIME_SPEC = `${RUNTIME_PACKAGE}@${RELEASE_VERSION}`;
14
14
  export const BOOTSTRAP_SPEC = `${BOOTSTRAP_PACKAGE}@${RELEASE_VERSION}`;
15
15
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@asc-agent/runtime",
3
- "version": "0.5.1",
3
+ "version": "0.5.2",
4
4
  "description": "ASC (Agent Session Control) \u2014 local-first human-in-the-loop agent control plane: core, CLI, and adapters",
5
5
  "keywords": [
6
6
  "agent",