docs: raw accept points an occupied captured-bundle name at --replaces-bundle (#177)
CI / verify (push) Successful in 5m36s
CI / pwsh (push) Successful in 2m5s
Release / release (push) Successful in 36s

The ON FAILURE reaction for an occupied folder name still said there is no
--replaces for a folder; for a captured bundle that sent a new edition down
the rename route. raw/CONTRACT.md names the manifest as a captured folder's
source of the capture fields.

Files changed:
- CHANGES.md
- VERSION
- raw/CONTRACT.md
- tools/CONTRACT.md
- tools/chemenu/commands/raw_cmd.py

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnAJ7Z3CpVD3PRbN73QtU2
This commit is contained in:
torbenandClaude Opus 5.5 committed 2026-10-05 12:13:09 +02:00
1 parent 311c8ee059
commit 8ce202a34e
5 files changed
+20 -6

No files matched your search

+11 -1
View File
@@ -59,7 +59,7 @@ concern - readable here, never shipped as something to parse.
---
## 8.0.0-beta.41 - 2026-10-05 - raw capture / raw status / --replaces-bundle: documentation from git repositories as a bundle, with drift reporting
## 8.0.0-beta.42 - 2026-10-05 - raw accept: an occupied folder name held by a captured bundle points at --replaces-bundle
**Author:** Torben Nehmer
@@ -152,8 +152,18 @@ concern - readable here, never shipped as something to parse.
- kb/CONTRACT.md names section anchors in wikilinks and the Broken Anchors finding
- kb/CONTRACT.md names unwritten scaffold sections and the Unfilled Template Sections finding
- wiki-ingest and wiki-manage call xref add with --rel, not the --rel-a/--rel-b removed in 4.0.0
- raw accept: an occupied folder name held by a captured bundle points at --replaces-bundle
<!-- /wikitool:bumps -->
### raw accept: an occupied folder name held by a captured bundle points at --replaces-bundle
The ON FAILURE reaction `raw accept incoming/<folder>` prints for an occupied name still said
"rename the folder - there is no `--replaces` for a folder". For the new edition of a captured
bundle that is the wrong route: renaming makes it a second, separate source. The reaction now
names `--replaces-bundle` for a name held by a captured bundle and keeps renaming for every other
folder. `raw/CONTRACT.md` § "Getting a file in" says the same about the capture fields of a
captured folder: they come from its manifest, not from one flag pair (Gitea #177).
### raw capture / raw status / --replaces-bundle: documentation from git repositories as a bundle, with drift reporting
Documentation from a git repository used to reach an instance only by hand: copy the files into
+1 -1
View File
@@ -1 +1 @@
8.0.0-beta.41
8.0.0-beta.42
+3 -1
View File
@@ -85,7 +85,9 @@ tools/wikitool raw accept --fidelity verbatim --authority reporting incoming/pro
The folder name is the bundle name, so the name rule below applies to it and not to the files
inside: two `README.md` in different subfolders are no conflict. A folder is accepted alone, with
one `--fidelity`/`--authority` pair for all of it, and `incoming/projekt-x` is gone afterwards.
one `--fidelity`/`--authority` pair for all of it - a folder `raw capture` wrote takes the pair
from its manifest instead ([below](#getting-a-repository-in-raw-capture)) - and
`incoming/projekt-x` is gone afterwards.
Every check runs before anything moves: an empty folder is refused, and so is one with a hidden
entry (a name starting with `.`), a symlink or a special file anywhere below it - each is named.
That is what keeps the clean-up safe: only directories the moves emptied are removed, so no file
+1 -1
View File
@@ -1656,7 +1656,7 @@ Promote one or more files, or one folder, from `incoming/` into `raw/`.
**ON FAILURE**
- raw accept: A file does not exist or is not directly in `incoming/`; two files in one call share a filename; a target path already exists; or a target path would be over the path budget (160 UTF-16 code units below the instance root) -> Fix the named argument and retry once. A file inside a subdirectory of `incoming/` is accepted with its whole folder (`raw accept incoming/<folder>`) or moved up into `incoming/` first. For a path over the budget, rename the file in `incoming/` to something shorter - the refusal comes before anything moves, so `incoming/` and `raw/` are unchanged
- raw accept incoming/<folder>: The folder is not directly in `incoming/`, is combined with another argument, `--page` or `--replaces`, holds no file, or holds a hidden entry, a symlink or a special file; a target path is over the budget; or the folder name is already occupied under `raw/` -> Nothing moved. Fix what the message names and retry once; for an occupied name, rename the folder in `incoming/` - there is no `--replaces` for a folder
- raw accept incoming/<folder>: The folder is not directly in `incoming/`, is combined with another argument, `--page` or `--replaces`, holds no file, or holds a hidden entry, a symlink or a special file; a target path is over the budget; or the folder name is already occupied under `raw/` -> Nothing moved. Fix what the message names and retry once. For an occupied name held by a captured bundle, the folder is its new edition: `raw accept incoming/<bundle> --replaces-bundle <raw-bundle>`. Any other occupied name: rename the folder in `incoming/` - such a folder has no replacement form
- raw accept: `--fidelity`/`--authority` is missing, or names `unknown` or a value outside the schema's enum -> Pass both with a valid value, then retry once
- raw accept: The target name is already occupied anywhere under `raw/` by something the call does not own -> Not fixed by retrying: the refusal names `--replaces` (same source, new edition) and renaming in `incoming/` (a separate source) as the two routes, and neither is the tool's to pick. Show the message to the user and wait
- raw accept: `--page` names an unknown page or one with no `raw_files:` yet, an existing `raw_files:` entry is missing on disk, a file to be moved has more than one owning page, or `--page` would overwrite an already-set `fidelity`/`authority` with a different value -> Fix the named argument and retry once; a different capture value on an existing page is a new edition - `--replaces`
+4 -2
View File
@@ -1056,8 +1056,10 @@ def _replace_bundle(
"`--page` or `--replaces`, holds no file, or holds a hidden entry, a symlink or a "
"special file; a target path is over the budget; or the folder name is already "
"occupied under `raw/`",
reaction="Nothing moved. Fix what the message names and retry once; for an occupied "
"name, rename the folder in `incoming/` - there is no `--replaces` for a folder",
reaction="Nothing moved. Fix what the message names and retry once. For an occupied "
"name held by a captured bundle, the folder is its new edition: `raw accept "
"incoming/<bundle> --replaces-bundle <raw-bundle>`. Any other occupied name: rename "
"the folder in `incoming/` - such a folder has no replacement form",
),
cli_contract.Failure(
label="raw accept",