oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1# Changed files: bounded per-file diffs
2
3Implemented on `changes/diff`, based on main 70e4880 with a normal merge.
4The controller approved the design on 2026-11-26; the final diff protocol is 35 (renumbered from 34 on 2026-11-27).
5
6## Decisions
7
8One complete file patch fits one bounded base64 durable frame. This avoids
9persisting partial, unscanned bytes. The collection remains separately bound
10and requires a matching accepted Engineering report before device reads.
11Both ends use the module-pinned Gitleaks 8.30.1 embedded default rules; no
12repository configuration, baseline, path allowlist or inline ignore is read.
13The scanner library logger is permanently disabled to prevent findings from
14reaching diagnostic logs. Known-token checks also run on decoded layers.
15
16## Test-first record
17
18All Go commands use `GOMAXPROCS=2 GOTOOLCHAIN=go1.26.11 CGO_ENABLED=0`, `-p 1`.
19Only focused tests run locally because the shared Mac is loaded.
20
21- `go test -p 1 ./internal/wire -run 'TestProtocol32ChangeDiffs|TestDisplayPatchBounds' -count=1`:
22 failed first (missing types), then passed after implementation. Strict
23 downgrade rejects upload frames and removes the report reference below 32.
24- `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`:
25 failed first (missing Check), then caught encoded-token and private-key-header
26 gaps. Added decoded-layer token detection and conservative private-key-header
27 withholding. No fixture weakened to accept those cases.
28- `go test -p 1 ./internal/runner/thin -run 'TestCollectChangeDiffs|TestDisplayPatchClip' -count=1`:
29 failed first (missing collector), then passed. Covers Unicode rename, clean
30 text, secret withholding, binary, large blobs, cancellation and patch caps.
31- `go test -p 1 ./internal/equipo/chat -run 'TestChangeDiffUploadBinding|TestChangeDiffPublicationAndRead' -count=1`:
32 failed first (missing upload/read functions).
33
34## Result
35
36Protocol 35 transports complete bounded file patches separately from task views.
37The instance checks runner, person, task, step, attempt, base, candidate, digest,
38path, byte count and collection binding, and scans before storing. Only a
39matching accepted Engineering report publishes the collection. Device reads
40use task-read visibility, exact listed paths, a second roster/candidate check
41and no-store. Patches never enter lists, snapshots or Coordinator prompts.
42
43Limits: 200 files, 1 MiB/blob, 8 MiB input, 64 KiB/2,000 complete lines/file,
442 MiB/candidate, 128 KiB encoded response, 10 seconds collection time. Unaccepted
45bytes expire after 15 minutes; accepted bytes after seven days. The sweep and
46uploads prune expired bytes. Superseded candidates are deleted even if the next
47runner uploads no replacement. A private attempt-bound deadline preserves the
48expired state after pruning. Collection failure leaves Engineering unchanged;
49the existing Review measurement test proves identical gate results before and
50after display collection.
51
52Native renders selectable plain monospaced text with added/removed styling,
53character wrapping on iPhone and horizontal scrolling on Mac. Open on Amadan
54stays outside the scroll area. Late or mismatched file/candidate responses are
55discarded. All unavailable reasons retain the Amadan action.
56
57## Validation
58
59Restored-code focused Go tests passed with Go 1.26.11, CGO disabled,
60GOMAXPROCS=2 and `-p 1`:
61
62- Wire protocol/downgrade, patch shape and all display bounds.
63- Shared scanner: encoded/known tokens, private key headers, cancellation,
64 oversized input, and hostile repository scanner settings.
65- Runner: clean patches, Unicode rename, initial commit, binary/oversized blobs,
66 input caps, complete before/after scanning, clipping and hostile Git config.
67- Store: upload bindings, replay, publication, expiry, candidate retention,
68 tampering, encoded response cap, revoked membership and stale-candidate race.
69- `TestContractChangeDiffs`: real stream upload/report/device read, no-store,
70 no patches in ordinary task views and unchanged merge authority.
71- `TestConversationMigrationSnapshot`, `TestAPIErrorCopyKeys`,
72 `TestOpsAreWhatTheHandlersWrite|TestSchemaFollowsEncodingJSON`.
73- `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`:
74 two table-driven tests passed for transport/bounds/plain line styling and
75 late-response cancellation.
76- Native fixtures/schema, 334 exact web strings, identity and sign-in lifetime
77 checks passed. Mac and unsigned iPhone Simulator builds passed.
78- `make fmt-check`, `make budget` (93 directories) and `make copy-release-check`
79 passed. Size allowances use measured counts, retaining earlier reasons.
80 The new GET has a device-only JSON perf record: indexed lookup, no Git/network.
81
82The loaded-machine instruction overrides the usual full local gate. No full
83native/Go suite or local perf run; Linux CI is the full Go/performance gate.
84Its exact-head verdict is delivered with the SHA. The added UI test was not
85run; direct fixture-app screenshots were inspected instead. The owned simulator
86was stopped/deleted and the fixture Mac app stopped.
87
88## Mutation results
89
9052 mutations killed, then restored. Commands below returned nonzero with a
91relevant failing assertion. Two initially invalid scan mutants were repaired
92and rerun. Initially surviving fixtures were strengthened: isolate newline and
93UTF-8 guards, use a valid index/total pair, test blob caps directly, and use
94distinct before/after files so Git rename detection cannot mask a removed scan.
95
96- `runner` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
97- `person` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
98- `attempt` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
99- `base` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
100- `candidate` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
101- `engineering` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
102- `running` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
103- `retired` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
104- `cancel` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
105- `moving` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
106- `size` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
107- `digest` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
108- `order` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
109- `candidate-byte-cap` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
110- `file-count` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
111- `instance-rescan` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
112- `accepted-only` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
113- `expiry` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
114- `response-cap` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
115- `wire-path` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
116- `wire-bytes` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
117- `wire-lines` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
118- `wire-utf8` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
119- `wire-nul` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
120- `wire-withheld` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
121- `scan-known` in `internal/diffscan/scan.go`: **KILLED**. `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`.
122- `scan-decoded` in `internal/diffscan/scan.go`: **KILLED**. `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`.
123- `scan-private-header` in `internal/diffscan/scan.go`: **KILLED**. `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`.
124- `scan-rules` in `internal/diffscan/scan.go`: **KILLED**. `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`.
125- `scan-inline-ignore` in `internal/diffscan/scan.go`: **KILLED**. `go test -p 1 ./internal/diffscan -run TestScanClosed -count=1`.
126- `runner-blob-cap` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
127- `runner-aggregate` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
128- `runner-mode` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
129- `runner-before-scan` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
130- `runner-after-scan` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
131- `runner-line-cap` in `internal/runner/thin/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/runner/thin -run TestCollectChangeDiffs|TestDisplayPatchClip|TestDisplayBlobSafetyAndInputBudget|TestCollectionScansBeforeAfterAndBeyondCut -count=1`.
132- `native-bearer` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
133- `native-response-cap` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
134- `native-task` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
135- `native-candidate` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
136- `native-path` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
137- `native-byte-cap` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
138- `native-lines` in `native/apple/Sources/EquipoKit/API/ChangeDiff.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
139- `native-late-response` in `native/apple/Sources/EquipoKit/Presentation/ChangeDiffModel.swift`: **KILLED**. `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests`.
140- `publication-hash` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
141- `second-candidate` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
142- `second-roster` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
143- `prune-pending` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
144- `discard-superseded` in `internal/equipo/chat/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/equipo/chat -run ^TestChangeDiff -count=1`.
145- `frame-downgrade` in `internal/wire/runners.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestProtocol32ChangeDiffs -count=1`.
146- `report-downgrade` in `internal/wire/runners.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestProtocol32ChangeDiffs -count=1`.
147- `complete-lines` in `internal/wire/change_diffs.go`: **KILLED**. `go test -p 1 ./internal/wire -run TestDisplayPatchBounds -count=1`.
148
149Raw mutation scripts/results and validation logs are archived beside the
150screenshots in `site/build/slice5b/validation/`, outside this repository.
151
152## Screenshots
153
154`~/amadan.net/oficina/polish-audit/equipo-daily-driver/site/build/slice5b/`:
155`iphone-diff.png`, `iphone-diff-large.png`, `mac-diff.png`. Production sheet,
156fake device transport, long lines; the large iPhone capture uses Accessibility
157XL. Wrapping, scrolling and the visible Amadan action were inspected.
158
159## Copy review
160
161Luna approved all five on 2026-11-26, replacing the unavailable sentence below.
162The source and both native catalogs now record that approval.
163
164- `native.diff.withheld`: This file’s changes are hidden because they may contain a secret.
165- `native.diff.too_large`: This file is too large to show here.
166- `native.diff.unavailable`: These changes aren’t available. Open on Amadan to review them.
167- `native.diff.expired`: These changes have expired. Open on Amadan to review them.
168- `native.diff.truncated`: Only part of this file’s changes is shown. Open on Amadan for the rest.
169
170Binary reuses `native.changes.binary`. Stale-candidate errors use the literal
171reviewed `preview_changed` code and `api.preview_changed` words. No server copy
172was added. Native copy review is resolved; Fable review remains with the controller.
173
174## First Linux CI result and corrections
175
17658c9c213 compiled and passed the copy step. CI caught a stale protocol-99
177negotiation expectation (31 instead of 32), four budget reasons over 200 bytes,
178and the new scanner package's missing budget TestMain hook. Fixed those test
179integration issues and reran their narrow checks. The same run had timeouts in
180TestContractChecksPlacedOnTheWorker, TestBrowserCopyContinue and webread's
181TestTimeouts; all three passed their automatic retries. No timeout assertion or
182production behavior was weakened. The subsequent head is the final CI gate.
183
184Staticcheck also rejected the deprecated detect.Fragment API. The scanner now
185uses the supported DetectSource API with one complete bounded in-memory
186fragment, no path and no filesystem/archive reader. Govulncheck found reachable
187GO-2026-6888, GO-2026-6865 and GO-2025-3922 through the newly imported scanner.
188Raised only the named dependencies to patched versions: brotli 1.2.7,
189klauspost/compress 1.20.2, and ulikunitz/xz 0.5.15. Gitleaks and its embedded
190rules remain pinned at 8.30.1. No finding was suppressed.
191
192After correction, the focused scanner/runner/store/stream tests passed.
193Staticcheck v0.7.0 and govulncheck v1.8.0 on internal/diffscan, targeting
194linux/amd64, passed; govulncheck reported zero reachable vulnerabilities.
195
196Luna follow-up: regenerated catalogs, string checks and parity passed.
197The implementation head 05c89179 passed Linux CI including perf before this
198copy-only follow-up; delivery reports the new head and its CI verdict.
199
200## Fable delta review, 2026-11-26
201
202The normal merge of main includes `602b91fe` (the landed check-db diagnostic).
203Main had meanwhile shipped unfinished-work capability 32, and the controller
204reserved 33 for the open Assistant attachments branch. The controller allocated
205`ProtocolChangeDiffs = 34`. Diff references and frames are stripped/refused for
20632 and 33, with frozen StepReport key sets and unfinished-work semantics tested.
207The controller will not land or release this branch before
208`design/assistant-attachments` (protocol 33) lands. If that branch stalls, the
209controller will coordinate renumbering. Keep 34 meanwhile. No code from that
210open branch was merged.
211
212The instance computes `hidden_characters` from every Unicode Cf code point on
213the returned patch. This covers bidi controls, marks, isolates, zero-width
214characters and other format characters. Patch bytes and collection hashes stay
215unchanged; this is a device response field, not runner-supplied authority.
216Native also detects the characters locally for older responses. It shows the
217approved notice and renders each character as a highlighted code-point marker.
218The initial Mac cap and original-byte Copy described by this review have been
219replaced by the second-review fixes below. Both platforms now wrap all text,
220and Copy contains the displayed markers.
221
222The new notice is `native.diff.hidden_characters`: “This file contains hidden
223characters that can change how code reads. They are shown as codes.” Approved
224by Luna, 2026-11-26, in both generated catalogs. Copy reuses `chat.paste.copy`.
225
226The shared runner/instance scanner now refuses URLs with nonempty embedded
227passwords, before and after supported decoding. Detector panic and error tests
228exercise the actual detector boundary as well as rule-loading failures.
229
230Tests were extended before implementation: the password fixture failed at
231runtime; missing hidden-character fields/rendering helpers failed to compile.
232Focused wire/scanner/store and native tests then passed. Mutation outcomes and
233final validation are recorded below before delivery. Local commands remain
234limited to two workers and focused tests under the loaded-Mac ruling.
235
236All seven reported survivor mutations now fail at runtime: own forge credential
237omission, scanner panic as clean, scanner error as clean, nonliteral pathspecs,
238runner candidate-byte cap removal, retired-step read allowance, and publication
239with fewer files than the facts. The literal-path regression exercises both
240blob lookup and the diff command; the latter catches Git wildcard expansion.
241
242Additional killed mutations: embedded-password scan removal, hidden-character
243flag removal, Unicode Cf detection removal, native marker removal, notice
244removal, Mac line cap removal, and loss of the full copy text. All mutations
245were restored. Logs and scripts are archived in `site/build/slice5b/validation-review/`.
246
247Focused wire/scanner/store tests passed; runner diff tests passed (7.770s),
248including real Git candidate caps and credential withholding. The device
249contract sends a hostile bidi patch through the real upload/report/read route
250and verifies the flag and unchanged bytes (1.364s). Native ChangeDiffTests
251passed, as did string parity, catalog checks, Mac build, iPhone Simulator build,
252formatting, measured size budgets and release-copy checks.
253
254An overly broad local `Test.*Diff` selector also picked unrelated
255`TestPreviewRejectsDifferentAncestor` (local preview scanner unavailable) and
256`TestTokenCheckUnfinished` (token-card timeout). Neither assertion was changed;
257the corrected focused selection passed. Linux CI remains the full gate under
258the controller's instruction to avoid full local suites.
259
260New visual evidence: `mac-hidden-characters.png` and
261`iphone-hidden-characters.png` in `site/build/slice5b/`. Both use the production
262diff sheet and fake device transport, with RLO/PDF and zero-width-space code
263markers and the reviewed notice. No real project or credential is involved.
264
265CI at `daeedf1e` found the device schema's new flag did not match the generated
266contract: the always-emitted bool must be required, and its description belongs
267in `wireschema` as well as the generated document. Both are corrected. The
268focused `TestPersonAPIDeviceContract` is now included in local validation.
269
270## Second Fable review: visible characters and complete Mac text
271
272The Go flag and native presentation now cover every Cf and
273Default_Ignorable_Code_Point, U+2028/U+2029, and every Cc except TAB and LF.
274The controller explicitly keeps LF structural. CR is marked, including in
275CRLF files; that case also displays the approved hidden-character notice.
276NUL remains refused by patch validation, and is still covered by the display
277predicate. Original patch bytes, path acceptance and merge authority do not change.
278
279`internal/wire/testdata/hidden-codepoints.json` is consumed by Go and Swift:
28065 ranges, 4,422 code-point cases including visible/structural negative cases.
281Its Cf and Default_Ignorable ranges come from Unicode 17's
282[UnicodeData](https://www.unicode.org/Public/17.0.0/ucd/UnicodeData.txt) and
283[DerivedCoreProperties](https://www.unicode.org/Public/17.0.0/ucd/DerivedCoreProperties.txt).
284The fixture includes all default-ignorable ranges, including unassigned points,
285Hangul fillers, CGJ, variation selectors and tags. The Go union of Cf,
286Other_Default_Ignorable_Code_Point and Variation_Selector covers the same set;
287Swift uses its scalar properties. Tests also pin Cf characters excluded from
288Default_Ignorable_Code_Point, so dropping either class fails.
289
290Mac now uses selectable NSTextView with character wrapping in the vertical
291scroll view. There is no line truncation and no horizontal scroll requirement.
292The layout regression measures the real text container at widths 240, 560 and
293800, with 2,000 spaces before `evil()`, and verifies those glyphs are inside the
294view's measured bounds. A separate 60,000-character line keeps its trailing code.
295Rendering and whole-file Copy use the same visible text, including marker codes
296and actual LF separators. The Copy button remains outside the patch and copies
297the whole displayed file; native selection also copies only visible text.
298File rows, folder headers, rename sources, accessibility labels and the sheet
299header use the same escaping. Request URLs still use the original validated path.
300
301The CRLF regression exposed another issue: Swift Character treats CRLF as one
302grapheme, so the old suffix check rejected it and the line counter missed it.
303Both now inspect Unicode scalars, matching Go. CRLF is accepted within the bounds,
304renders `⟨U+000D⟩` before each real line break, and counts toward the 2,000-line cap.
305The scanner now also withholds empty-username password URLs such as
306`redis://:secret@host`; runner collection and instance acceptance tests cover it.
307No new copy was introduced.
308
309Test-first evidence (logs in `site/build/slice5b/validation-review2/`):
310
311- `GOMAXPROCS=2 GOTOOLCHAIN=go1.26.11 CGO_ENABLED=0 go test -p 1 ./internal/wire ./internal/diffscan -run 'TestPatchHiddenCharacters|TestEmbeddedPasswordURL' -count=1` failed for missing scalar classes and the empty username, then passed.
312- `swift test --package-path native/apple --jobs 2 --filter ChangeDiffTests` failed for missing markers, raw Copy and lost trailing code. The added CRLF test separately failed three assertions before its fix.
313- Restored `swift test --package-path native/apple --jobs 2 --filter 'ChangeDiffTests|ChangeFilesTests'`: 21 tests passed.
314- Focused wire, scanner, chat, device route and generated OpenAPI contract tests passed, as did the runner credential/URL withholding test.
315- String parity (334 web strings), catalog checks, API/Markdown fixtures, Oficina ID and sign-in lifetime checks passed. Mac and iPhone builds use two jobs. Full local suites remain deferred under the loaded-Mac ruling; Linux CI is the full gate.
316- `make fmt-check budget copy-release-check` passed. Wire's measured source count is 7,535; no time budget was raised.
317
318All 19 deliberate mutations failed at runtime, then were restored:
319
3201. Go Cf detection removed.
3212. Go Other_Default_Ignorable detection removed.
3223. Go Variation_Selector detection removed.
3234. Go Cc detection removed.
3245. Go U+2028 detection removed.
3256. Go U+2029 detection removed.
3267. Empty URL username refused by the password detector's pattern.
3278. Native Cf detection removed.
3289. Native Default_Ignorable detection removed.
32910. Native Cc detection removed.
33011. Native U+2028 detection removed.
33112. Native U+2029 detection removed.
33213. Copy returns original hidden bytes.
33314. File name rendering returns raw paths.
33415. Rename source rendering returns raw paths.
33516. Display cuts a line at 2,000 characters.
33617. Character wrapping replaced by clipping.
33718. CRLF line counting reverted to Character iteration.
33819. CRLF suffix validation reverted to Character suffix matching.
339
340The mutation runner, exact commands and per-mutation logs are archived with the
341validation evidence. Protocol remains 34. The controller will land/release only
342after Assistant attachments 33 lands, or coordinate a separate renumbering.
343
344Visual evidence was recaptured from this branch: `iphone-hidden-characters.png`,
345`mac-hidden-characters.png`, `mac-hidden-filenames.png`, and `mac-long-line.png`
346in `site/build/slice5b/`. The long-line capture visibly includes `evil()` after
3472,000 spaces. All were inspected. The owned simulator was terminated, shut down
348and deleted, and the Mac fixture apps were closed after capture.
349
350## Held-branch follow-ups after approval of be924467
351
352Protocol remains 34 and the branch remains held for Assistant attachments 33.
353The Mac paragraph style now gives wrapped continuations a font-relative hanging
354indent (three times the font’s point size), while each original diff line
355starts at zero. The real NSTextView layout test verifies that `evil()` after
3562,000 spaces is below and to the right of its original `+`, at three view widths.
357The indent is layout, not inserted text, so Copy retains the displayed contents.
358
359FE0E and FE0F immediately after an allowed pictographic base remain in their
360normal presentation, without a marker or hidden-character flag. Following the
361controller's tightening of 37e88207, Go and native use the same pinned Unicode 17
362intersection of Emoji and Extended_Pictographic, excluding bases below U+00FF
363and U+203C, U+2049 and U+2122. This retains ⚠️ while excluding ASCII digits, #,
364*, ©, ®, ™, ‼, ⁉, regional indicators and emoji modifiers. The source is Unicode's
365[Emoji data](https://www.unicode.org/Public/17.0.0/ucd/emoji/emoji-data.txt).
366The shared fixture checks every allowed base with both selectors and every
367removed Emoji base, plus explicit identifier and keycap sequences. It contains
368412 ranges and 7,664 cases. `admin1` + FE0F, `1` + FE0F, `#` + FE0F, `©` + FE0F,
369and digit/#/* keycaps all keep their visible selector markers and flags.
370Selector-only text, ordinary text bases, intervening whitespace, repeated
371selectors, other variation selectors and tags still get markers and flags.
372Filename rendering and Copy share the same contextual exception. The generated
373OpenAPI description documents it; no protocol or copy change is involved.
374
375The new shared-fixture cases failed on Go and Swift before implementation.
376The added native layout assertions also failed because the continuation's x
377coordinate was zero. Focused tests then passed. Machine checks precede each
378heavy command: `sysctl -n vm.loadavg`, `sysctl -n vm.swapusage`, and the process
379list, collapsing children of one heavy job. Commands wait above load 20 or when
380two other heavy jobs are running. Jobs run serially, with four workers and a
38110-minute timeout; no local full gate or unfiltered suite is run.
382
383All 11 follow-up mutations failed at runtime and were restored: omit FE0E,
384omit FE0F, omit the Emoji-base guard, remember the last Emoji instead of the
385immediate predecessor, and exempt other selectors/tags (each on Go and native),
386plus removal of the Mac hanging indent.
387
388The tighter-base regression first failed with the old implementation on both
389sides (Go's shared fixture; native's 8-test diff suite, 400 assertion issues).
390After implementing the restricted tables, both passed. Eight further mutations
391were killed at runtime and restored: re-enable ASCII bases, re-enable ©/®,
392re-enable ™/‼/⁉, and re-enable non-pictographic Emoji bases (regional indicators
393and modifiers), each in Go and native. These tests cover visible rendering,
394the hidden-character notice, and exact displayed Copy text, including keycaps.
395The existing Mac continuation screenshot remains representative: ⚠️ is still an
396allowed pictographic pair, and the FE0F after ordinary text remains marked.
397
398Final narrow validation:
399
400- `GOMAXPROCS=4 GOTOOLCHAIN=go1.26.11 CGO_ENABLED=0 go test -p 4 ./internal/wire ./internal/plan3test -run '^(TestPatchHiddenCharacters|TestPersonAPIDeviceContract)$' -count=1`: passed.
401- `swift test --package-path native/apple --jobs 4 --filter ChangeDiffTests`: 8 passed after restoring mutations.
402- `swift build --package-path native/apple --jobs 4 --product EquipoMac`: passed.
403- Native catalog and web parity checks passed. `make fmt-check budget` passed,
404 with wire remaining within its 7,709-line cap after restricting the base table.
405- `mac-long-line.png` was recaptured and inspected: `evil()` is visibly indented
406 under its `+`; `⚠️` keeps its normal presentation, while FE0F after `x` is marked.
407 The bounded capture process terminated and waited for its fixture app. No
408 simulator was needed or started for these follow-ups.
409
410Commands, machine checks, red/green and mutation logs, and the final CI receipt
411are archived in `site/build/slice5b/validation-held-followups/`.
412
413## Renumbered to protocol 35 (2026-11-27)
414
415Main landed `ProtocolAssistantFiles = 33` and `ProtocolPlaces = 34`, so
416this branch merged origin/main `be28c0c8` normally and moved to
417`ProtocolChangeDiffs = Protocol35` (`ProtocolCurrent`).
418
419- **Downgrade (`runners.go`).** Encode runs the diff step first: it refuses a
420 `change_diff` upload below 35 and drops a step report's `change_diffs`.
421 Main's Places (below 34) and Assistant-files (below 33) downgrades follow,
422 and accumulate `changed` instead of overwriting it.
423- **Frozen key sets.** StepReport keys are frozen and identical at 32, 33 and
424 34 (main changed no StepReport field); `TestDiffDowngradeFrozen32To34` checks
425 all three. Main's Places test (byte-identical at 34, refused or dropped
426 at 33) and its Assistant-files test (byte-identical at 33) are unchanged
427 apart from the current/`Spoken(99)` value.
428- **Current-protocol assertions.** Every one now names `ProtocolChangeDiffs`,
429 or 35. Negotiation now maps 35 to 35 and 99 to 35.
430- **Migration.** The branch's `0111_change_diffs.sql` collided with main's
431 `0111_notification_actions.sql`. It was renamed to `0113_change_diffs.sql`
432 and its schema block follows main's 0111 and 0112 in `schema.sql`.
433 `Models` lists both new records.
434- **Runner wiring (`run.go`).** Main's Engineer gained `ConfirmMint` and
435 `SiteChanged`; the branch's `DiffSecrets` is kept beside them.
436- **OpenAPI.** A structural three-way merge of base, branch and main. It
437 had no conflicts, and its changes from main are additions only (ChangeDiff
438 and its operation beside RetryTask, places and `placement_question`).
439- **Strings.** `strings.json` keeps both sides' keys. `check-strings.py`'s
440 approval comment rule adds the `native.diff.` prefix to main's rule, and
441 the catalogs were regenerated with `--write`. No new strings.
442- **Budgets.** Size exemptions were raised to the measured counts. Main's
443 card-read comment and the branch's diff perf skip are both kept.
444
445Checks:
446
447- `./internal/wire/...` passes.
448- These pass with `-tags testbuild`: `internal/equipo` (migrations and
449 snapshot), `chat`, `thintest` and `plan3test` for Diff, Place,
450 AssistantFile, Protocol and Contract, and `runner/thin` for TestChangeDiff,
451 TestDiff, TestPlaces and TestAssistantFile.
452- Linux build, budget size, TestBudgetRecordsAreShort, plan3-copy-check and
453 check-strings pass.
454- Native `ChangeDiffTests` pass: 8 of 8.
455- A wider `runner/thin` selection hit three tests:
456 `TestPreviewRejectsDifferentAncestor`, `TestPreviewReplacesInPlace` and
457 `TestResearchHandoffNothingToPlace`. Those are among the known
458 macOS-unreliable tests in that package, so hub CI decides them.
459