ruvnet-brain 3.4.5-dev → 3.4.6-dev

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
@@ -4,7 +4,7 @@
4
4
 
5
5
  # 🧠 RuvNet Brain
6
6
 
7
- ### 🧠 RuvNet Brain — [![RuvNet Brain version 3.4.5-dev — updated 2026-07-17 09:40 EDT](https://img.shields.io/badge/version_3.4.5--dev-updated_2026--07--17_09:40_EDT-1E90FF?style=for-the-badge&labelColor=0757BA)](https://github.com/stuinfla/ruvnet-brain/blob/main/plugin/.claude-plugin/plugin.json)
7
+ ### 🧠 RuvNet Brain — [![RuvNet Brain version 3.4.6-dev — updated 2026-07-17 09:40 EDT](https://img.shields.io/badge/version_3.4.6--dev-updated_2026--07--17_09:40_EDT-1E90FF?style=for-the-badge&labelColor=0757BA)](https://github.com/stuinfla/ruvnet-brain/blob/main/plugin/.claude-plugin/plugin.json)
8
8
 
9
9
  **A portable, source-grounded brain over Reuven Cohen's (rUv's) RuvNet stack — delivered as a Claude Code plugin that makes Claude _use_ the stack instead of fighting it.**
10
10
 
package/bin/install.mjs CHANGED
@@ -907,19 +907,26 @@ function runUpdate() {
907
907
  printBanner('update');
908
908
  const kbDir = resolvedKbDir();
909
909
  info(`brain dir: ${c.bold(kbDir)}`);
910
- if (!fs.existsSync(path.join(kbDir, 'forge-update.mjs'))) {
911
- missingUpdaterHelp(kbDir);
912
- process.exit(1);
913
- }
914
- info(c.dim("running the bundle's own self-updater (backs up first, re-verifies, never half-applies)…\n"));
915
- // Relative filename + matching cwd — same launch convention as smokeQuery(); stdio:'inherit'
916
- // streams the updater's narration live and unedited.
917
- const r = spawnSync(process.execPath, ['forge-update.mjs', '--apply'], { cwd: kbDir, stdio: 'inherit' });
918
- if (r.error) {
919
- console.error(`\n${c.red('✗ update failed to launch:')} ${r.error.message}`);
920
- process.exit(1);
910
+ let updateStatus = 1;
911
+ if (fs.existsSync(path.join(kbDir, 'forge-update.mjs'))) {
912
+ info(c.dim("running the bundle's own self-updater (backs up first, re-verifies, never half-applies)…\n"));
913
+ // Relative filename + matching cwd — same launch convention as smokeQuery(); stdio:'inherit'
914
+ // streams the updater's narration live and unedited.
915
+ const r = spawnSync(process.execPath, ['forge-update.mjs', '--apply'], { cwd: kbDir, stdio: 'inherit' });
916
+ updateStatus = r.error ? 1 : (r.status === null ? 1 : r.status);
917
+ }
918
+ // FALLBACK (2026-07-17). The bundle's self-updater is missing OR failed — e.g. an OLDER bundle whose
919
+ // canonicalManifestUrl points at the dead main/kb/.last-built.json path and 404s (the exact break a
920
+ // real user, Jan Lafko, hit). NEVER leave the user stranded at a 404: re-run THIS installer as a
921
+ // fresh install, which pulls the latest Release DIRECTLY (releases/latest) and never touches the
922
+ // manifest — so --update always succeeds and self-heals the stale SOURCE.json in one shot.
923
+ if (updateStatus !== 0 && !process.env.RUVNET_BRAIN_NO_UPDATE_FALLBACK) {
924
+ warn("\nthe bundle's own updater couldn't complete — falling back to a fresh install of the latest Release (this always works)…\n");
925
+ const self = fileURLToPath(import.meta.url);
926
+ const fr = spawnSync(process.execPath, [self, '--force'], { stdio: 'inherit',
927
+ env: { ...process.env, RUVNET_BRAIN_NO_UPDATE_FALLBACK: '1' } });
928
+ updateStatus = fr.error ? 1 : (fr.status === null ? 1 : fr.status);
921
929
  }
922
- const updateStatus = r.status === null ? 1 : r.status;
923
930
  // `--update --auto` = update now AND enroll in Evergreen, so this is the LAST time it's ever run by
924
931
  // hand. Only enroll if the update itself succeeded — never promise "you're set forever" on a failed
925
932
  // update. enableNightly() prints its own real verification (plist path + launchctl result).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ruvnet-brain",
3
- "version": "3.4.5-dev",
3
+ "version": "3.4.6-dev",
4
4
  "description": "One-command installer for RuvNet Brain — a portable, source-grounded brain over rUv's RuvNet building blocks, delivered as a Claude Code plugin so Claude uses the stack instead of fighting it.",
5
5
  "type": "module",
6
6
  "bin": {