fix: v2.3.1 — correct version, say why a plugin update failed, gitignored files in Files
- v2.3.0's tree reported 2.2.1, so every install saw an update forever; package.json, the lockfile, openapi.yaml, the CLAUDE.md marker and the snapshot now read 2.3.1 - A failed plugin-update step records the tail of the command's stdout and stderr plus its exit code or signal (failureText); plugin-bootstrap.js prints its refusal on stdout, which the verdict used to drop. Update all uses the same text - updates.test.js never applies an update: it skips when the checkout is behind a release (apply ran npm run setup and pruned dev dependencies) - Files tree lists gitignored files and folders, named in orange (addIgnored in git-diff.js); change-tree rows indent in whole steps
This commit is contained in:
@@ -26,6 +26,8 @@ const fs = require("fs");
|
||||
const { rotateIfLarge } = require("./log-rotate");
|
||||
const path = require("path");
|
||||
const { execFileSync, spawnSync } = require("child_process");
|
||||
// What a failed command printed — plugin-bootstrap.js says why on STDOUT.
|
||||
const { failureText } = require("./plugin-update-helper");
|
||||
|
||||
const [, , runtimeDirArg, planJson] = process.argv;
|
||||
|
||||
@@ -229,7 +231,7 @@ function main() {
|
||||
} catch (err) {
|
||||
// A marketplace that can't be refreshed (offline, auth) does not stop the
|
||||
// batch: the plugins may still have updates from the marketplaces that did.
|
||||
finishStep(mktStep, "failed", { error: String(err.stderr || err.message).slice(0, 2000) });
|
||||
finishStep(mktStep, "failed", { error: failureText(err).slice(0, 2000) });
|
||||
}
|
||||
|
||||
const self = plan.selfPlugin;
|
||||
@@ -243,7 +245,7 @@ function main() {
|
||||
run(claude, ["plugin", "update", id, "-y"], 600_000);
|
||||
finishStep(step, "ok");
|
||||
} catch (err) {
|
||||
finishStep(step, "failed", { error: String(err.stderr || err.message).slice(0, 2000) });
|
||||
finishStep(step, "failed", { error: failureText(err).slice(0, 2000) });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -253,7 +255,7 @@ function main() {
|
||||
try {
|
||||
run(claude, ["plugin", "update", selfId, "-y"], 600_000);
|
||||
} catch (err) {
|
||||
finishStep(step, "failed", { error: String(err.stderr || err.message).slice(0, 2000) });
|
||||
finishStep(step, "failed", { error: failureText(err).slice(0, 2000) });
|
||||
reloadPanes();
|
||||
state.status = "failed";
|
||||
state.finished_at = new Date().toISOString();
|
||||
@@ -281,7 +283,7 @@ function main() {
|
||||
} catch (err) {
|
||||
log(`bootstrap failed: ${err.message}`);
|
||||
state.status = "failed";
|
||||
state.bootstrap_error = String(err.stderr || err.message).slice(0, 2000);
|
||||
state.bootstrap_error = failureText(err).slice(0, 2000);
|
||||
state.note = "the old server was stopped; run /agenthub-update to recover";
|
||||
flush();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user