G5: fix version-count copy; record the u-system namespace finding

'There are 1 saved versions' is exactly the sloppiness the vocabulary law
exists to catch. Copy is design material, not decoration.

G5.9 records something the live test surfaced: a repo created through
X-Service-Token lands in a 'u-system' namespace because the service caller has
no identity of its own. Correct for /internal plumbing, WRONG for anything a
person owns — the portal must pass an acting user and this cell must refuse to
create a user-owned project without one. Until then service-created repos are
ops artifacts, not customer data.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Grant Whitmer
2026-08-11 15:59:41 -04:00
parent 3a9259a0da
commit 066de34489
2 changed files with 12 additions and 1 deletions

View File

@@ -291,8 +291,12 @@ async def list_versions(
return {
"versions": versions,
"count": len(versions),
# "There are 1 saved versions" is the kind of sloppiness the vocabulary
# law exists to catch. Copy is design material, not decoration (I-9).
"speak": (
f"There are {len(versions)} saved versions of '{repo.display_name}'. "
f"'{repo.display_name}' has 1 saved version. You can go back to it."
if len(versions) == 1
else f"'{repo.display_name}' has {len(versions)} saved versions. "
"You can go back to any of them."
if versions
else f"'{repo.display_name}' is empty so far."