aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAgando <roduccomm@gmail.com>2026-10-27 08:31:56 +0100
committerAgando <roduccomm@gmail.com>2026-10-27 08:32:39 +0100
commit197ab31e1dc915a991b3d88697e0fc4c294563a8 (patch)
tree2ae9521045cf93e40a2b1ac3cadbdc75079315d8
parent78149467b099465b9d0396bdd3916ba8507917ba (diff)
fix(newos4): print the checkpoint name actually saved (auto)
Task 2 + ship of plan 2026-10-27_061724-newos4-checkpoint-name-mismatch.md. module-system.js `checkpoint` read the clock a second time for the printed name, so the name in "✅ Checkpoint created: <name>" differed from the name on disk by >=1ms whenever no explicit name was given. It now prints the value returned by fs.checkpoint(). try/catch and error strings unchanged. Bundles rebuilt (rebuild-bundles.py); LATEST_VER in module-loader.js and all three ?v= tags in main.html (core-bundle, module-loader, critical-ext-bundle) bumped v4.6.101 -> v4.6.102. Verification: $ node --check modules/core/module-system.js SYNTAX OK $ node --check modules/core/core-bundle.js BUNDLE SYNTAX OK $ node modules/test/test-vfs-checkpoint.js (x5) test-vfs-checkpoint: 10 passed, 0 failed $ curl -s https://webx11.duckdns.org/spaces/newos4/main.html | grep -o 'core-bundle.js?v=[^"]*' core-bundle.js?v=v4.6.102 $ python3 scripts/newos4-maintain.py PASS: version v4.6.102 x3 in main.html (expect 3) ... maintenance result: OK $ python3 scripts/newos4-skill-audit.py skill audit: 7/7 pass
-rw-r--r--main.html6
-rw-r--r--modules/core/core-bundle.js7
-rw-r--r--modules/core/module-loader.js2
-rw-r--r--modules/core/module-system.js5
4 files changed, 9 insertions, 11 deletions
diff --git a/main.html b/main.html
index 86c034c..b3d2c39 100644
--- a/main.html
+++ b/main.html
@@ -1349,13 +1349,13 @@
</script>
<!-- v4.5.63: A2A scratchpad fixes + agent-register arg fix -->
-<script src="modules/core/core-bundle.js?v=v4.6.101"></script>
+<script src="modules/core/core-bundle.js?v=v4.6.102"></script>
<!-- Async dependency-ordered module loader now only initializes terminal and loads optional ext modules -->
-<script src="modules/core/module-loader.js?v=v4.6.101"></script>
+<script src="modules/core/module-loader.js?v=v4.6.102"></script>
<!-- Critical ext bundle loads AFTER webx11 exists so registerModule calls work -->
-<script src="modules/ext/critical-ext-bundle.js?v=v4.6.101"></script>
+<script src="modules/ext/critical-ext-bundle.js?v=v4.6.102"></script>
<script>
// ═══ ONE TRUE VERSION SOURCE ═══
diff --git a/modules/core/core-bundle.js b/modules/core/core-bundle.js
index 32ff73b..cd510b7 100644
--- a/modules/core/core-bundle.js
+++ b/modules/core/core-bundle.js
@@ -968,7 +968,7 @@ class VirtualFileSystem {
const toDelete = sorted.slice(0, all.length - 3);
for (const old of toDelete) this.deleteCheckpoint(old);
}
- return true;
+ return name;
}
rollback(name) {
const raw = this.fsReadJSON('/_snapshots/checkpoint-' + name + '.json');
@@ -6062,9 +6062,8 @@ Only output XML function calls for tool tasks. If no tool is needed, answer norm
this.commands['checkpoint'] = (args) => {
try {
const name = args[0] || '';
- this.terminal.fs.checkpoint(name);
- const displayName = name || new Date().toISOString();
- this.terminal.print('✅ Checkpoint created: ' + displayName, 'success');
+ const created = this.terminal.fs.checkpoint(name);
+ this.terminal.print('✅ Checkpoint created: ' + (created || name), 'success');
} catch (e) {
this.terminal.print('Checkpoint failed: ' + e.message, 'error');
}
diff --git a/modules/core/module-loader.js b/modules/core/module-loader.js
index 252c34b..b278f51 100644
--- a/modules/core/module-loader.js
+++ b/modules/core/module-loader.js
@@ -4,7 +4,7 @@
// Core module bundle loaded synchronously in main.html.
// This loader only handles version cache-busting, splash, terminal init, and optional ext modules.
- const LATEST_VER = 'v4.6.101';
+ const LATEST_VER = 'v4.6.102';
const CACHE = '?v=' + LATEST_VER;
const stored = localStorage.getItem('webx11_cache_ver');
if (stored !== LATEST_VER) {
diff --git a/modules/core/module-system.js b/modules/core/module-system.js
index b9b62a6..40b0861 100644
--- a/modules/core/module-system.js
+++ b/modules/core/module-system.js
@@ -479,9 +479,8 @@
this.commands['checkpoint'] = (args) => {
try {
const name = args[0] || '';
- this.terminal.fs.checkpoint(name);
- const displayName = name || new Date().toISOString();
- this.terminal.print('✅ Checkpoint created: ' + displayName, 'success');
+ const created = this.terminal.fs.checkpoint(name);
+ this.terminal.print('✅ Checkpoint created: ' + (created || name), 'success');
} catch (e) {
this.terminal.print('Checkpoint failed: ' + e.message, 'error');
}