nf start, nf editor and nf dev exit 0 when the processes they start fail

未关闭
#277 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
72/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
bun, node.js, typescript
领域
backend, cli

调研方向

Read src/lib/package-manager/package-manager.ts and the start, editor, and dev actions under src/action/actions/, then trace how AbstractAction.resolveResult handles keepAlive and failures. Check the existing tests for these actions and process management. Done means child failures stop the other processes, produce a failure message and nonzero exit, and the editor URL is printed only after /healthz responds.

由索引模型根据 Issue 内容生成。

描述

bug command:dev command:editor command:start
Which package is this bug report for?

@nanoforge-dev/cli

Which command is this bug report for?

start

Issue description

nf start, nf editor and nf dev exit with code 0 when the processes they start fail (read from the code, not run).

Effects: a nf start whose loader can't bind its port or read its TLS files exits 0 in CI and in scripts. When only the client or only the server fails, the other one keeps running and the CLI only prints START_PART_FAILED. nf editor prints "Editor running!" (src/action/actions/editor.action.ts#L33) before the editor has started, and prints it even when the editor crashes.

Expected: when a child fails, the others are stopped and the command exits non-zero with its failure message. The editor URL is printed once /healthz answers.

Found during a read-only audit of main at e95b881 (2026-11-11).

Code sample
// start.action.ts
await Promise.all(tasks);   // each task resolves even when its loader failed
return { keepAlive: true }; // -> resolveResult returns early, no exit code
Versions
  • @nanoforge-dev/cli 3.0.1 (main, e95b881)
  • Node.js 26.7.0
  • Bun 1.3.14 (bundled)
  • Linux
Issue priority

Medium (should be fixed soon)

I have tested this issue on a development release

No response

主要语言
TypeScript
星标
2
派生
2
平均合并
2 天 18 小时
30 天内合并 PR
17

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

NanoForge-dev/CLI 的其他 Issue

查看 NanoForge-dev/CLI 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。