67dcb773afe1
count saves, objects, events and checkpoints in words that agree with the number, and say plainly when the update server answers with something that is not a release (3.2.10)
- time
- 2026-09-28 18:27 UTC · 2 weeks ago
- machine
- Junes-MacBook-Pro.local
- agent
- claude-opus-5-5
- session
- clear feedback
- parent
- ac15999ac9b4
↓ koh-67dcb773.tar.gzatlas at this save
files changed7 files
VERSION+1 −1src/cli/cmd_doctor.v+2 −1src/cli/cmd_migrate.v+1 −1src/cli/cmd_offer.v+2 −2src/cli/cmd_strip.v+2 −2src/update/update.v+2 −1v.mod+1 −1src/cli/cmd_doctor.v+2 −1
@@ -10,6 +10,7 @@1010 import json21111 import os1212 import time13+import src.fmt1314 import src.history1415 import src.snapshot1516 import src.storage@@ -57,7 +58,7 @@5758 warn(problem)5859 }5960 }60- note('${report.objects} objects · ${report.saves} saves · ${report.checkpoints} checkpoints')61+ note('${fmt.plural(report.objects, 'object')} · ${fmt.plural(report.saves, 'save')} · ${fmt.plural(report.checkpoints, 'checkpoint')}')6162 if report.backup != '' {6263 ok('backed up to ${report.backup}')6364 }src/cli/cmd_migrate.v+1 −1
@@ -39,7 +39,7 @@3939 return 04040 }4141 ok('migrated ${fmt.plural(report.saves, 'save')} from Koh 2 (lane ${report.lane})')42- note('${report.checkpoints} checkpoints · ${report.flags} flags · ${report.objects} objects')42+ note('${fmt.plural(report.checkpoints, 'checkpoint')} · ${fmt.plural(report.flags, 'flag')} · ${fmt.plural(report.objects, 'object')}')4343 warn_unsafe_paths(report.unsafe_paths)4444 note('the Koh 2 data is untouched in ${migrate.archive_dir}/ — move it back to go back')4545 if report.ignore_carried {src/cli/cmd_offer.v+2 −2
@@ -83,7 +83,7 @@8383 ok('the remote already has everything from [${report.head}]')8484 return 08585 }86- ok('offered ${report.saves} saves · ${report.objects} objects · ${report.events} events to "${report.repo}"')86+ ok('offered ${fmt.plural(report.saves, 'save')} · ${fmt.plural(report.objects, 'object')} · ${fmt.plural(report.events, 'event')} to "${report.repo}"')8787 note('remote head is now [${report.head}]')8888 return 08989 }@@ -170,7 +170,7 @@170170 return171171 }172172 if !quiet && report.saves + report.objects + report.events > 0 {173- note('offered to "${report.repo}" — ${report.saves} saves · ${report.objects} objects')173+ note('offered to "${report.repo}" — ${fmt.plural(report.saves, 'save')} · ${fmt.plural(report.objects, 'object')}')174174 }175175 }176176 src/cli/cmd_strip.v+2 −2
@@ -90,11 +90,11 @@9090 }9191 if scope.files > 0 {9292 ok('stripped ${path} from ${fmt.plural(local.files_removed, 'file')} across ${fmt.plural(scope.saves, 'save')}')93- note('${local.objects_dropped} objects dropped')93+ note('${fmt.plural(int(local.objects_dropped), 'object')} dropped')9494 }9595 if !sent.skipped {9696 if sent.failed == '' {97- note('the remote was updated: ${sent.remote.records} save records rewritten, ${sent.remote.objects} objects dropped')97+ note('the remote was updated: ${fmt.plural(sent.remote.records, 'save record')} rewritten, ${fmt.plural(sent.remote.objects, 'object')} dropped')9898 } else {9999 warn('the remote could not be updated: ${sent.failed} — run the same strip again to finish it')100100 }src/update/update.v+2 −1
@@ -68,7 +68,8 @@6868 return error('${url} answered ${response.status_code}')6969 }7070 document := json2.decode[Document](response.body) or {71- return error('${url} is not a release document: ${err.msg()}')71+ // The parser's own message, carets and colour included, means nothing here.72+ return error('${url} did not answer with a release document — try again later')7273 }7374 if document.version == '' {7475 // A document with no version is not a release document, so say that ratherv.mod+1 −1
@@ -1,6 +1,6 @@11 Module {22 name: 'koh3'3- version: '3.2.9'3+ version: '3.2.10'44 description: 'One SQLite file per repo, one line of history.'55 license: 'MIT'66 }