| 1 | # Native Docs review record |
| 2 | |
| 3 | 2026-09-13: independent specification review dispatched as gpt-6-astra with high reasoning. Actual runtime identity was not independently verified. The amended specification was approved after adding native known-schema editing parity, twelve locales/accessibility, sandboxed CRDT decoding, bounded per-document recovery, explicit UTF-16 positions, memory-only content and current stream authorization. |
| 4 | |
| 5 | Final independent production branch review: approved at `c2e1a92`, against |
| 6 | inherited `d5ff04e17144583620ff3b9950fcf6722e7001e9`, with the evidence and manual |
| 7 | acceptance limits below. The review covered the working web inventory, native |
| 8 | Mac/iOS implementation, current authorization, sealed server storage, lossless |
| 9 | CRDT identity/formatting, own-only undo, generation/recovery transitions, native |
| 10 | clipboard/export, and the three narrowly scoped Yrs deletion backports. No |
| 11 | additional concrete production blocker was established after the persisted-rule |
| 12 | regression passed. The reviewer authored the isolated UI targets/runner and |
| 13 | independent wire/deletion probes; production implementation was reviewed |
| 14 | independently. This does not claim exhaustive manual parity acceptance. |
| 15 | |
| 16 | The final original server CI and native engine/Apple gate passed. All six |
| 17 | parallel Mac/simulator/device builds passed in |
| 18 | `../native-build-logs/20260913T095810.093604Z/results.json`. Source review preserves |
| 19 | normal Yrs garbage collection; it does not adopt an unbounded tombstone policy. |
| 20 | |
| 21 | ## Isolated native review |
| 22 | |
| 23 | The review app, UI test runner, and Go fixture are separate test targets. They |
| 24 | use a fresh temporary database and the real native approval/exchange flow. |
| 25 | They never access a production account. |
| 26 | |
| 27 | Run from the repository root with a booted simulator and the Go toolchain |
| 28 | required by `go.mod` on PATH: |
| 29 | |
| 30 | ```sh |
| 31 | python3 native/scripts/review-ios.py --simulator SIMULATOR_UUID |
| 32 | ``` |
| 33 | |
| 34 | The runner builds the review app and UI tests before starting the fixture, then |
| 35 | installs both bundles. It starts `TestNativeReviewFixture`, checks that its exact |
| 36 | native credential can read the document list, and writes mode-0600 |
| 37 | `Documents/review.json` into each current simulator container. The app and test |
| 38 | runner each read their own file; neither uses a hardcoded host temporary path. |
| 39 | |
| 40 | UI execution has a seven-minute limit inside the fixture's ten-minute lifetime. |
| 41 | On success, failure, or timeout, cleanup stops the test processes, signals the |
| 42 | fixture to finish, terminates the review bundles, and deletes credentials from |
| 43 | both original and current containers. Resolving containers again handles Xcode |
| 44 | reinstalling an application during the test. |
| 45 | |
| 46 | Logs and the `.xcresult` bundle remain under `native/build/review-TIMESTAMP`. |
| 47 | `--go /path/to/go` selects a toolchain explicitly. `--skip-build` reuses already |
| 48 | rebuilt artifacts. `--smoke` verifies authentication, credential installation, |
| 49 | and cleanup without claiming editor acceptance. |
| 50 | |
| 51 | The orchestration smoke test passed on 2026-09-13 with simulator |
| 52 | `5064842A-8777-44F3-9AFF-E6562CF88F71`. On the same iPhone simulator, the native |
| 53 | create/type/Bold/append flow passed with exact body and formatting verified via |
| 54 | a fresh authenticated Markdown export. Its screenshot was visually inspected. |
| 55 | The runner removed both credentials and stopped the fixture afterward. |
| 56 | The same accepted binary passed the identical flow and fresh server read on |
| 57 | iPad Pro 13-inch (M5), iOS 26.5, with simulator |
| 58 | `C12B219D-0114-4EB6-A75B-6F6565D422CD`. |
| 59 | |
| 60 | `--only testCreateTypeFormatAndPersistDocument` isolates that case; |
| 61 | `--only testExportPDFAndMarkdownDestinationsAndCancellation` isolates export. |
| 62 | Export acceptance opens both native destination pickers and cancels; the runner |
| 63 | asserts no private export staging remains and cleans it on failure too. |
| 64 | An actual external destination write is outside these cases. |
| 65 | On the iPad simulator, both export picker/cancel flows passed in 24.458 seconds. |
| 66 | Their screenshots were visually inspected: each picker displays “Native review |
| 67 | document”. The runner confirmed that no export staging directory remained and |
| 68 | removed both review credentials before stopping the fixture. |
| 69 | |
| 70 | The latest iPhone build also passed `testCreateTypeFormatAndPersistDocument` |
| 71 | with exact saved body and bold formatting in |
| 72 | `native/build/review-20260913T092049.526154Z/Review.xcresult`; credentials and |
| 73 | fixture cleanup passed. This covers the generation-reuse and explicit-selection |
| 74 | changes as well as ordinary typing. |
| 75 | |
| 76 | Additional review cases are `testInputRuleReversalAndMultilinePersistence`, |
| 77 | `testKeyboardJumpSearchOpensDocument`, and `testJumpButtonSearchOpensDocument`. |
| 78 | The final rebuilt iPhone rule case passed in 16.859 seconds in |
| 79 | `native/build/review-20260913T095637.456828Z/Review.xcresult`. It verifies native |
| 80 | prefix removal, Backspace restoration, multiline typing, and the exact fresh |
| 81 | server Markdown body. The earlier extra empty list is absent after the three |
| 82 | targeted Yrs deletion backports. Its screenshot was visually inspected; fixture |
| 83 | and credential cleanup passed. |
| 84 | |
| 85 | The iPhone jump-button case passed in |
| 86 | `native/build/review-20260913T094927.493167Z/Review.xcresult`: native search uses |
| 87 | the real ranked endpoint and the selected result opens the second document. |
| 88 | The review-only `testRegisteredCommandAndSoftwareSubmitOpenDocument` case and |
| 89 | selected XCTest suite passed in 20.223 seconds, recorded in |
| 90 | `native/build/review-20260913T100847.314877Z/ui.log`. |
| 91 | It locates the actual focused native editor, verifies its registered Command-K |
| 92 | binding and priority, dispatches that fixed selector through UIKit's responder |
| 93 | chain, searches the real endpoint, and submits with software-keyboard newline. |
| 94 | The second document's native editor opens. Xcode then hung while finalizing its |
| 95 | result bundle; the owned runner was interrupted and its normal cleanup removed |
| 96 | credentials and stopped the fixture. Direct synthetic screenshots were retained. |
| 97 | This is passing XCTest evidence, not a successful final xcodebuild exit. The |
| 98 | fixed-command probe is confined to the separate review target and has no |
| 99 | production launch hook. |
| 100 | |
| 101 | Physical hardware keyboard acceptance remains unverified. iPad `typeKey` |
| 102 | occasionally opened search but also inserted a literal K; hardware Return |
| 103 | injection did not open the result even after adding an explicit key handler. |
| 104 | One hardware-connection attempt had the same Return result, and restored the |
| 105 | original `ConnectHardwareKeyboard=0` preference afterward. These failed HID |
| 106 | cases remain diagnostics and are not claimed as passing. The phone keyboard |
| 107 | case explicitly skips: Apple's [XCUIElement overview](https://developer.apple.com/documentation/xcuiautomation/xcuielement) |
| 108 | documents keyboard interaction for macOS and iPadOS; attempted iPhone Command-K |
| 109 | injection produced a literal K. |
| 110 | |
| 111 | Other unexecuted manual matrices remain listed in `PARITY.md`: full formatting |
| 112 | and clipboard UI combinations, simultaneous live editing across devices, native |
| 113 | sharing, VoiceOver/native-speaker review, final destination writes/print, and |
| 114 | interactive Mac close/menu behavior. Their implemented paths and targeted |
| 115 | tests were reviewed; those matrices are not represented as manually completed. |
| 116 | |
| 117 | A failed XCTest case now gets 45 seconds for Xcode to finalize its result bundle; |
| 118 | if Xcode remains stuck, the runner stops only its own test process group and |
| 119 | cleans up. This failure path was exercised. The seven-minute total test bound |
| 120 | still applies. Synthetic jump screenshots are also written by the separate test |
| 121 | runner and copied into the private review log directory during cleanup, so they |
| 122 | survive an incomplete `.xcresult`; their originals are removed afterward. |
| 123 | |