@ouro.bot/cli 0.1.0-alpha.200 → 0.1.0-alpha.201

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.json CHANGED
@@ -1,6 +1,12 @@
1
1
  {
2
2
  "_note": "This changelog is maintained as part of the PR/version-bump workflow. Agent-curated, not auto-generated. Agents read this file directly via read_file to understand what changed between versions.",
3
3
  "versions": [
4
+ {
5
+ "version": "0.1.0-alpha.201",
6
+ "changes": [
7
+ "fix: don't launchctl bootstrap after daemon start \u2014 was starting competing daemon that killed the first"
8
+ ]
9
+ },
4
10
  {
5
11
  "version": "0.1.0-alpha.200",
6
12
  "changes": [
@@ -1298,14 +1298,10 @@ function defaultEnsureDaemonBootPersistence(socketPath) {
1298
1298
  return;
1299
1299
  }
1300
1300
  const homeDir = os.homedir();
1301
- const launchdDeps = {
1302
- exec: (cmd) => { (0, child_process_1.execSync)(cmd, { stdio: "ignore" }); },
1301
+ const writeDeps = {
1303
1302
  writeFile: (filePath, content) => fs.writeFileSync(filePath, content, "utf-8"),
1304
- removeFile: (filePath) => fs.rmSync(filePath, { force: true }),
1305
- existsFile: (filePath) => fs.existsSync(filePath),
1306
1303
  mkdirp: (dir) => fs.mkdirSync(dir, { recursive: true }),
1307
1304
  homeDir,
1308
- userUid: process.getuid?.() ?? 0,
1309
1305
  };
1310
1306
  const entryPath = path.join((0, identity_1.getRepoRoot)(), "dist", "heart", "daemon", "daemon-entry.js");
1311
1307
  /* v8 ignore next -- covered via mock in daemon-cli-defaults.test.ts; v8 on CI attributes the real fs.existsSync branch to the non-mock load @preserve */
@@ -1319,7 +1315,12 @@ function defaultEnsureDaemonBootPersistence(socketPath) {
1319
1315
  });
1320
1316
  }
1321
1317
  const logDir = (0, identity_1.getAgentDaemonLogsDir)();
1322
- (0, launchd_1.installLaunchAgent)(launchdDeps, {
1318
+ // Write plist only — do NOT launchctl bootstrap.
1319
+ // The daemon is already running (started by ouro up). Bootstrapping would
1320
+ // start a SECOND daemon via launchd's RunAtLoad, causing a race where
1321
+ // killOrphanProcesses kills the first daemon and both end up dead.
1322
+ // The plist on disk is sufficient: launchd picks it up on login.
1323
+ (0, launchd_1.writeLaunchAgentPlist)(writeDeps, {
1323
1324
  nodePath: process.execPath,
1324
1325
  entryPath,
1325
1326
  socketPath,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ouro.bot/cli",
3
- "version": "0.1.0-alpha.200",
3
+ "version": "0.1.0-alpha.201",
4
4
  "main": "dist/heart/daemon/ouro-entry.js",
5
5
  "bin": {
6
6
  "cli": "dist/heart/daemon/ouro-bot-entry.js",