mastracode 0.31.1-alpha.3 → 0.31.1-alpha.4
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.md +18 -0
- package/dist/{chunk-27ZZNWIA.cjs → chunk-EAGGG466.cjs} +11 -13
- package/dist/chunk-EAGGG466.cjs.map +1 -0
- package/dist/{chunk-K7V3PH2V.js → chunk-RATAY5IF.js} +11 -13
- package/dist/chunk-RATAY5IF.js.map +1 -0
- package/dist/cli.cjs +6 -6
- package/dist/cli.js +2 -2
- package/dist/tui/commands/update.d.ts.map +1 -1
- package/dist/tui/mastra-tui.d.ts.map +1 -1
- package/dist/tui.cjs +18 -18
- package/dist/tui.js +1 -1
- package/package.json +9 -9
- package/dist/chunk-27ZZNWIA.cjs.map +0 -1
- package/dist/chunk-K7V3PH2V.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# mastracode
|
|
2
2
|
|
|
3
|
+
## 0.31.1-alpha.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Fixed the auto-updater falsely reporting success when the update landed somewhere the running binary doesn't use. Previously any exit code 0 from the package manager was treated as success, so if Mastra Code was installed by a different tool (for example via a wrapper that puts a shim on your PATH), `npm install -g` could update a copy you never run and Mastra Code would still tell you to restart onto the "new" version. ([#18792](https://github.com/mastra-ai/mastra/pull/18792))
|
|
8
|
+
|
|
9
|
+
Mastra Code now verifies the install before and after updating when the install location and version are detectable:
|
|
10
|
+
- Before installing, it checks that the running binary lives in the package manager's global directory when that directory can be determined. If it doesn't (for example when the install is managed by another tool), it skips the pointless install and tells you immediately which install to update instead.
|
|
11
|
+
- When the install is owned by a tool it recognizes, it delegates the update to that tool: vite-plus installs are updated by running `vp install -g` for you, and Homebrew installs (under any prefix, including Linuxbrew) get the exact `brew upgrade mastracode` command to run.
|
|
12
|
+
- On Windows, update commands now run through a shell so the package managers' `.cmd` shims launch correctly.
|
|
13
|
+
- When the installed version is readable, it only reports "Updated" when the running binary changed to the target version.
|
|
14
|
+
- If the package manager reports success but the running binary is unchanged, it tells you honestly that your installation is managed by another tool and to update it with that tool, instead of claiming success.
|
|
15
|
+
- When an update fails, it now surfaces the package manager's error output so you can see the cause, rather than just "Auto-update failed".
|
|
16
|
+
|
|
17
|
+
- Updated dependencies [[`55b6ecd`](https://github.com/mastra-ai/mastra/commit/55b6ecd1083d21d00ea19488e721e451de75e76f), [`4cfdd64`](https://github.com/mastra-ai/mastra/commit/4cfdd645794feaea0c4ea711e70ecdfbef0c5b8e)]:
|
|
18
|
+
- @mastra/code-sdk@0.2.0-alpha.4
|
|
19
|
+
- @mastra/core@1.52.0-alpha.4
|
|
20
|
+
|
|
3
21
|
## 0.31.1-alpha.3
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -14245,14 +14245,13 @@ Would you like to update now?`;
|
|
|
14245
14245
|
});
|
|
14246
14246
|
if (answer === "Yes") {
|
|
14247
14247
|
ctx.showInfo(`Updating to v${latestVersion}\u2026`);
|
|
14248
|
-
const
|
|
14249
|
-
if (
|
|
14250
|
-
ctx.showInfo(`Updated to v${latestVersion}. Please restart Mastra Code.`);
|
|
14248
|
+
const outcome = await updateCheck.performUpdate(pm, latestVersion);
|
|
14249
|
+
if (outcome.status === "updated") {
|
|
14251
14250
|
ctx.stop();
|
|
14251
|
+
console.info(outcome.message);
|
|
14252
14252
|
process.exit(0);
|
|
14253
14253
|
} else {
|
|
14254
|
-
|
|
14255
|
-
ctx.showError(`Auto-update failed. Run \`${cmd}\` manually.`);
|
|
14254
|
+
ctx.showError(outcome.message);
|
|
14256
14255
|
}
|
|
14257
14256
|
} else if (answer === "No") {
|
|
14258
14257
|
const s = settings.loadSettings();
|
|
@@ -17765,7 +17764,7 @@ function inertSession() {
|
|
|
17765
17764
|
};
|
|
17766
17765
|
}
|
|
17767
17766
|
function resolveAsset(name) {
|
|
17768
|
-
const here = path2.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('chunk-
|
|
17767
|
+
const here = path2.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('chunk-EAGGG466.cjs', document.baseURI).href))));
|
|
17769
17768
|
const candidates = [
|
|
17770
17769
|
path2.join(here, name),
|
|
17771
17770
|
// dev: src/tui/voice/native/<name>
|
|
@@ -21599,14 +21598,13 @@ Would you like to update now?`;
|
|
|
21599
21598
|
});
|
|
21600
21599
|
if (answer === "Yes") {
|
|
21601
21600
|
showInfo(this.state, `Updating to v${latestVersion}\u2026`);
|
|
21602
|
-
const
|
|
21603
|
-
if (
|
|
21604
|
-
showInfo(this.state, `Updated to v${latestVersion}. Please restart Mastra Code.`);
|
|
21601
|
+
const outcome = await updateCheck.performUpdate(pm, latestVersion);
|
|
21602
|
+
if (outcome.status === "updated") {
|
|
21605
21603
|
this.stop();
|
|
21604
|
+
console.info(outcome.message);
|
|
21606
21605
|
process.exit(0);
|
|
21607
21606
|
} else {
|
|
21608
|
-
|
|
21609
|
-
showError(this.state, `Auto-update failed. Run \`${cmd}\` manually.`);
|
|
21607
|
+
showError(this.state, outcome.message);
|
|
21610
21608
|
}
|
|
21611
21609
|
} else {
|
|
21612
21610
|
const settings = index$1.loadSettings();
|
|
@@ -21641,5 +21639,5 @@ exports.getThemeMode = getThemeMode;
|
|
|
21641
21639
|
exports.mastra = mastra;
|
|
21642
21640
|
exports.restoreTerminalForeground = restoreTerminalForeground;
|
|
21643
21641
|
exports.theme = theme;
|
|
21644
|
-
//# sourceMappingURL=chunk-
|
|
21645
|
-
//# sourceMappingURL=chunk-
|
|
21642
|
+
//# sourceMappingURL=chunk-EAGGG466.cjs.map
|
|
21643
|
+
//# sourceMappingURL=chunk-EAGGG466.cjs.map
|