Repository navigation
Ui Refinement Ux18 G
Published documentation mirror. Edit the source through a repository PR. See Project status.
The initial partial implementation addresses the transition-history component of UX18-G on the accepted UX18-F baseline. UX18-G.1 adds the persistent generation catalog. UX18-G.2 adds persistent historical seals, scoped exclusive leases and removes the operational generation and generation-child lifetime ceilings. This is not milestone acceptance or a new roadmap increment; G.3 receipt/query scaling and G.4 operational closure remain mandatory.
V1–V3 manifests remain readable. A nonempty legacy transition journal is imported on the next metadata commit or transition. V4 records the transition count and SHA-256 root rather than the entire ordered journal. The generation catalog, pool pins, handoff intent and namespace identity remain in the existing checksummed manifest. Immutable content-addressed pages under transition-history bind level and logical offset, contain at most 32 entries or child hashes, and are at most 2200 bytes. The root and all child references are checked, and the last transition must match the active committed slots. The signed 64-bit count bound follows the cursor representation rather than a development-era history ceiling.
Publication uses the existing private descriptor-relative directory, anonymous temporary inode, synchronized file/link and directory publication. New pages precede authoritative manifest publication; an interrupted write cannot make a transition committed without the manifest. Legacy import verifies the prefix; V4 interrupted extension must reproduce exactly the previous root with one appended transition. Metadata-only changes preserve the root. Unreferenced pages are not automatically removed. They are not acknowledged evidence and reclamation remains UX20.
Ordinary V4 appends and single-record lookups traverse only the affected bounded-depth tree path. Native pages are limited to 32 results. Startup verifies all referenced pages with bounded recursion and per-page allocations, but work is linear in history size. Old pages corrupted after startup are detected when accessed (or at next restart); the implementation does not rescan the complete tree before every operation. The V4 format uses the original inline generation catalog; UX18-G.1 moves this catalog into persistent records as described below. G.2 changes ownership of completed generations as described below.
The local IPC remains bounded at 64 request bytes and 128 volume-response bytes. Signed 64-bit cursors preserve sentinel values and canonical decimal parsing. Slots remain bounded at 128. Desktop notification history remains an eight-entry presentation bound and is not the persistent journal.
The native regression imports a synthetic V3 prefix of 4096 transition records, interrupts an actual handoff, recovers transition 4097, commits transition 4098, reads every ordered entry, checks preserved event identity and exact receipt retry, and rejects corrupted/missing referenced pages. The synthetic prefix is not evidence of 4096 real handoffs. The existing health-client regression checks wide cursors and overflow refusal. The existing executable-manager fixture extends its synthetic history to 4096, executes a real rollover via IPC and checks replay after restart. Target execution was subsequently successful on the intermediate candidate.
The intermediate transition candidate passed all 274 target automated gates (29m26s), including executable-manager wide cursor replay, private mount recovery and installed systemd qualification. Manual GUI review and the intermediate commit were reported; no PR or milestone acceptance.
V5 adds a generation count and digest root to the checksummed manifest in place of inline generation records. V1–V4 readers remain supported. Fresh bootstrap remains V1–V3; a subsequent metadata commit with a nonempty paged journal converts the catalog to V5. V4 is imported on a subsequent metadata commit, not rewritten merely by opening a store. The existing private transition-history directory now stores both kinds of immutable object: generation records and catalog radix pages have distinct format domains from transition pages. Records bind the ordinal, pair identity, role slots, paths and persistent identity bindings. Each record is capped at 8500 bytes; each catalog page uses at most 32 hashes and 2200 bytes. Digest, ordinal, canonical record encoding, page position, expected cardinality and binding mode are checked. Existing path disjointness, ownership and native pair checks remain in force.
The committed manifest remains the publication authority for both roots. New records and pages are synchronized before manifest replacement. In G.1 a normal rollover appended only the new generation record and its radix path; G.2 additionally seals the outgoing record. Active projection replacement updates only the last record and its path. Metadata-only commits preserve the catalog when unchanged. Legacy import and verified first-binding migration can rewrite all records. Pending recovery decodes and verifies both catalogs and compares the prior generation prefix under the existing linked-publication rules; a V5 pending publication may not regress to an older inline format. Unpublished objects are retained for later UX20 reclamation, not treated as committed evidence.
The regression creates 34 actual generations (33 rotations), constructs the exact V4 predecessor from real generation metadata, interrupts a V4-to-V5 rollover, reopens and recovers it, crosses the 32-entry radix boundary, verifies compact manifest size, exact retry and stable evidence, and refuses corrupt or missing referenced generation records. This is not qualification beyond 128 generations. The existing actual-manager wide cursor fixture reads and validates the V5 catalog when constructing its synthetic V3 history. Full target qualification remains required.
G.1 target qualification passed all 274 automated gates (29m20s), including actual-manager wide cursor and prior recovery fixtures. Manual GUI review and commit reported, no PR. At that checkpoint the 128-generation and 4096 generation-child ceilings and permanently resident historical stores remained.
V5 retains its root encoding and now admits distinct KNETSENTRY-GENERATION-2 records for completed generations. A sealed record adds a 64-character digest over a domain-separated pair identity, both persistent filesystem/directory bindings, and the canonical complete raw head (count and digest of all committed raw record hashes). The verified projection must contain exactly every committed raw record with its verified normalized values. The active record remains unsealed and mutable. Older generation-1 records remain readable; older binaries cannot interpret generation-2 records. The seal authenticates evidence relative to the trusted manifest root, not against wholesale rollback of that trusted control state or privileged same-user tampering.
Rollover verifies that all generations are fully indexed and derives each required seal while its original pair is exclusively owned. The new manifest publishes the seals and new active generation together; a failed publication leaves the owner poisoned and cannot acknowledge new evidence. Linked recovery re-derives any new seal and refuses alteration or removal of an existing seal, verifies the unchanged historical prefix and checks that the replacement active pair is empty. Seal-only legacy migration during configured manager recovery is permitted only if paths, pair identities, slots, bindings, pins, handoff and transition history are unchanged. Its pending publication is separately verified without inventing a transition. An inline legacy history with no recorded transitions remains on the original bootstrap representation until a real rollover. Historical unsealed legacy records retain the original owners until verified sealing succeeds, so a one-time legacy reopen can still require up to the original 128 pairs; modern sealed histories have no such descriptor growth.
After authoritative manifest synchronization, sealed historical native owners are released. The state namespace lock remains held for the entire manager lifetime. Each historical operation uses an exclusive scoped pair lease, validates the pinned original location and the canonical seal, then closes the descriptors. A competing standalone pair opener can acquire an idle historical pair (locks remain advisory), but while it owns the pair, the volume owner cannot obtain a lease or acknowledge a receipt from unverifiable history. A coherent content rollback, extension or replacement is refused against the catalog seal on reopening. The lease does not prevent a different process with filesystem write permission from damaging idle data; it detects this rather than pretending that advisory locks or digests provide hardware write protection. Historical leases never perform raw/index recovery or new-row admission. Exact historical retries preserve the original durability check; missing/corrupt or busy history causes refusal, not successful empty history or duplicate ACK.
The artificial 128-generation limit is removed for catalogued histories; legacy inline formats retain their original decoding bound. Modern histories above that limit require every historical record to have a committed seal. The representational limit derives from the signed 64-bit protocol event/revision range and worst-case per-generation revision contribution, not an arbitrary lifetime quota. Generation-shaped child enumeration remains streamed and verifies each child using the original no-symlink/no-cross-mount and ownership/mode rules, but no longer refuses at 4096 children. Configured slot bounds and individual evidence-generation record limits are unchanged.
Native qualification creates 131 actual generations with 130 rotations under RLIMIT_NOFILE=32, preserving IDs 1 and 16385 across restart and exact receipt retry. Idle descriptor samples are 4 before owner creation and at most 8 after handoffs; the enforced process limit also constrains transient descriptors. Regression covers a competing pair lock, coherent old-head/projection rollback before and after restart, restoration, and interrupted legacy seal-only publication. A separate fixture creates 4097 generation-shaped child directories (not 4097 evidence generations), verifies normal direct-layout access and rejects a symlink child. Existing G.1 corruption qualification follows the committed catalog root rather than obsolete record objects.
Remaining limitations: generation metadata and the pointer inventory are still materialized in memory; readiness, receipt lookup, cross-generation search/pending and full audits still scan retained generations. The direct-layout child scan is linear in directory population. G.2 bounds open native historical owners for sealed histories; it is not a claim of bounded total memory or latency independent of history length. Receipt indexing, persistent query revision handling and bounded working memory remain G.3; actual-manager extended workloads, target matrix and operational resource/endurance closure remain G.4. No older binary can read the new sealed record after publication. Use disposable evidence only until milestone qualification. Unreferenced metadata remains for UX20 reclamation; no evidence deletion is introduced.
G.2 target qualification passed all 274 automated gates (39m35s); manual GUI review and intermediate commit reported. No PR or milestone acceptance. G.3 adds a distinct KNETSENTRY-GENERATION-3 catalog record for configured, sealed generations. V5 manifest root encoding remains unchanged; the record adds a cumulative receipt root and count for the sealed prefix through that ordinal. Generation-1 and generation-2 readers remain supported. The individual generation record cap is 8600 bytes to accommodate the two new fields at maximum valid path lengths. - represents a verified empty prefix; a missing root denotes legacy metadata. Decode validates contiguous coverage, monotonic counts, per-generation policy bounds and unchanged roots for empty extensions.
The immutable compressed hexadecimal radix tree uses domain-separated SHA-256 receipt keys derived from the original 32-character endpoint portion of the binding and the parsed native cursor. Its leaves map keys to global event IDs, and branches carry a common prefix and at most 16 child references. Nodes are limited to 1200 bytes. A lookup reads one digest-verified path of strictly increasing prefix length (maximum 65 nodes), not historical raw records for every generation. Hash collisions or duplicate keys during insertion fail closed, and a historical match must still pass original pair ownership, seal verification, native receipt conflict/exact-retry checking and raw durability synchronization. A verified absence in the committed trie and active pair permits new admission, subject to all original path availability checks and the durable handoff barrier. No raw row, full binding or plaintext native cursor is stored in the trie; the hashes are not claimed to anonymize predictable cursor values. The trie is not a standalone receipt or an ACK authority. A lookup of a receipt from one verified generation need not open an unrelated temporarily locked historical pair; complete-history queries still refuse a busy or unverifiable required pair. A failed full sealed-history recovery audit blocks subsequent admission until a successful recovery audit.
Outgoing generation sealing and cumulative receipt-root/count publication use the same committed catalog and manifest boundary. Legacy seal-only or receipt-only migration recomputes roots from verified original evidence, and pending recovery re-derives candidate root/count extensions and verifies referenced objects before committing. An absent legacy root retains the existing scan-based lookup until verified migration succeeds. Missing/corrupt root or referenced lookup-path objects never establish a negative receipt result; observed receipt faults block subsequent operations until streamed tree verification and recovery. Reopen streams the committed tree for structural integrity and leaf-count verification. The control manifest remains the trust anchor; whole-trusted-state rollback is outside this seal model. Immutable superseded/unpublished objects remain for UX20 reclamation. Older binaries cannot read generation-3 records; use disposable evidence until milestone acceptance.
Search and pending now process a bounded result page with a single query snapshot per generation (in addition to scoped lease verification), map the global cursor directly into the relevant local ID range, and stop row enumeration when another matching row establishes more. Full generation validation still runs to preserve the previous complete-history and revision contract. The cumulative committed receipt count is checked against historical raw counts; revision remains 2 * generations + raw records + indexed records, preserving existing cursors and stale-page behavior across restart, indexing and migration. Neither the historical readiness checks nor the full sealed-media audit are removed. No new query IPC or GUI is introduced.
The added native regression uses three real generations, two historical receipt keys and active evidence. It verifies targeted lookup despite an unrelated historical lock, exact and conflicting retries, endpoint-specific cursor reuse, corrupt root and missing leaf refusal, blocking after an observed lookup fault, original object restoration, ascending/descending cursor pages and pending revision invalidation. It constructs generation-2 records for a synthetic migration predecessor, interrupts receipt-only publication, and verifies recovery with unchanged IDs, transition count and query revision. Existing real 131-generation, legacy publication and missing-media regressions remain mandatory. The actual-manager wide-cursor fixture accepts generation-3 records before constructing its intentionally synthetic V3 history.
Not complete: resident generation metadata and pointer vectors, startup and linked recovery materialization, history-wide readiness/catalog checks, and the manager's repeated full sealed-media/capacity audits remain proportional to retained history. Search/pending still verify all historical generations; their row enumeration is cursor-aware but total operation cost is not history-independent. The native candidate must not be represented as fulfilling bounded metadata working memory or end-to-end scalability. The remaining G.3 engineering must be resolved before G.4 can serve as final qualification. No software work is deferred to the physical ledger.
G.3 target qualification passed all 274 automated gates (38m18s); manual GUI review and intermediate commit reported. No G.3 corrective patch is required. The outstanding engineering is included in G.4, not a separate G.3.1 packet.
V5 catalog decoding and live ownership now use a GenerationInventory view referencing the committed count and root rather than retaining a vector of all generation records. Each access reads and digest-verifies the required radix path; the legacy inline formats alone retain a bounded vector. Candidate updates stage immutable objects and a separate root before authoritative manifest publication. Linked recovery compares and rederives candidate records without materializing the modern catalog. Sparse native ownership tracks only resident unsealed legacy owners and the active pair. Committed histories beyond 128 generations must retain no inline records and at most one resident native owner; historical pairs are opened through the existing verified exclusive lease. No new persistent format or storage authorization is introduced.
The manager now uses recover_capacity within its serialized storage-processing cycle. Successful configured recovery has already verified each sealed historical pair and its complete indexed projection. For a committed receipt-indexed sealed history, the combined invocation reuses that verification only for the immediately following active capacity read; it does not retain an audit-success cache between cycles. Legacy unsealed histories and unsuccessful recovery retain the independent capacity validation path. Pending publication, known integrity faults, unavailable or corrupted history and missing active ownership still refuse unsafe operation. All explicit complete-history queries, admission checks and separate capacity calls retain their existing verification semantics.
The extended native 131-generation regression verifies the combined recovery/capacity path under RLIMIT_NOFILE=32, refusal following coherent historical rollback and recovery after original evidence restoration. Existing migration, linked publication, receipt and catalog corruption regressions remain mandatory. No synthetic physical test is substituted for the actual manager or mount fixture.
Remaining limitations: persistent catalog working memory is bounded for modern sealed histories, but readiness checks, full sealed-media audits, search/pending, rotation and restart still traverse retained generations. Catalog lookup on each scan adds disk work; restart's pair/path disjointness verification still compares prior entries and has quadratic worst-case cost. Direct-layout child enumeration remains proportional to directory population. No constant-time admission or complete history verification is claimed. Actual executable-manager extended workload, scaling measurements and target qualification remain required; this candidate is not milestone closure. A later performance change must preserve the agreed fail-closed semantics rather than silently skipping required integrity checks.
The maintainer reported committing the G.4 intermediate revision without rerunning full local acceptance. G.3 remains the last fully target-qualified baseline. This continuation is within G.4; no new planned milestone is introduced.
Sequential catalog validation now uses a bounded-depth radix traversal, reading each page once per traversal rather than restarting at its root per record. The configured-manager startup path checks all entries against disjoint configured parent pools and validates exact pair/path uniqueness and direct-layout ordering in a disposable SQLite temporary database with a 256 KiB suggested page-cache size, file-backed temporary storage, no mmap, memory journal and automatic close. Only domain-separated SHA-256 digests of pair identities and paths enter this scratch index. It is not evidence, not authoritative or reused across opens, and requires a SQLite build permitting file-backed temporary storage; the platform's private temporary directory can receive scratch pages. Failure refuses startup. The nonconfigured compatibility path retains its previous pairwise checks. No raw rows or plaintext paths are written to the temporary index. This removes configured startup's quadratic prior-record comparisons; B-tree operations are logarithmic and scratch disk use grows with history. The cache size is a SQLite cache target, not a hard process RSS bound.
The ordinary serialized manager maintenance path checks all used configured parent identities and the active pair, verifies the committed receipt-root node, and opens at most 16 historical sealed pairs per tick. A fixed-size role-slot summary is rebuilt from the verified catalog on root change; the scrub cursor is volatile. Startup, explicit recovery, legacy migration, interrupted publication, observed receipt-index faults and active-media repair retain full verification. Once an integrity or availability fault is observed by a scrub, the sticky fault blocks subsequent admission until a complete successful sweep (or explicit full recovery). An ordinary status is the last known operational availability, not proof of a simultaneous fresh full-history audit; the worst-case discovery interval for unrelated individual historical corruption or lock contention grows with the number of slices. Parent loss is checked each tick. Explicit complete-history requests still check all required media immediately and refuse missing or inconsistent history. No new receipt ACK is based solely on the scrub's previous successful result: existing admission readiness, targeted pair and durability checks remain. For sealed receipt-indexed history, routine maintenance supplies a locally verified active pending ID rather than a second full pending query. Explicit indexing still revalidates its existing prerequisites. Rotation and capacity avoid rereading a verified complete sealed pair just to check its empty backlog.
The inherited 131-real-generation native fixture now tests a locked distant generation outside the first scrub slice, immediate explicit full-history refusal, subsequent scrub detection, sticky ACK refusal, full clean sweep recovery and active pending ID resolution. The catalog fixture also constructs checksummed duplicate pair and duplicate raw-path records and requires startup refusal. Native GCC and Clang ASan/UBSan regressions passed, including leak detection. No target clang-tidy/Clazy/Qt build is asserted. The actual-manager fixture has an explicit --scalability mode used by the existing private full acceptance gate: 127 additional IPC rotations after four actual generations, 131 actual pairs, 4224 journal transitions including the synthetic 4096-prefix, RLIMIT_NOFILE=64, sampled FD/RSS envelope, restart and historical directory loss/restoration. The implementation environment cannot run the production filesystem fixture; it remains required target qualification. No physical result is asserted.
Remaining constraint: this does not establish a history-independent admission, rotation or complete-history query latency. Fresh global availability validation requires traversing history under the current security contract. Steady-state routine scrub work is bounded, but a full scrub sweep, catalog publication/restart validation, and explicit strict readiness and complete-history operations remain history-dependent. The original strict bounded-per-operation processing objective cannot be reported fully closed by these changes. The maintainer can decide whether the strict global availability semantics are the intended exception to that objective; until then and until target integration succeeds, this is a development candidate, not accepted UX18-G. UX18-H remains separate; UX18 through UX18-F were already merged. No software work is deferred to the private physical ledger.
The target continuation run (2026-12-02 UTC) reported 3 PASS, 1 FAIL, 2 SKIPPED, 0 BLOCKED. The linux-analysis build stopped with two clang-analyzer-core.NonNullParamChecker diagnostics in GenerationInventory::at and visit; no subsequent build or runtime gates executed. The existing generic require(bool) throws on a false predicate, but the analyzer continued past the guard with a hypothetical null catalog location. This diagnostic does not demonstrate an actual runtime dereference.
Use an explicit terminating if (!loc_) throw Failure{StoreStatus::IntegrityFailure}; before all four catalog reference operations (read, streamed visit, replace and append). Convert analogous existing history-pointer predicates at journal and receipt boundaries to explicit terminating guards, preserving their previous failure classification and the order of remaining checks. No checker suppression, compiler configuration change, persistent format change or relaxed validation is introduced. The existing UX18-G structural verifier now requires the four explicit guards immediately before the respective calls. The inherited runtime regressions remain mandatory; the structural guard check is not a runtime null injection test. No new production fault injection interface is introduced.
Qualify the exact target analysis configuration first, then the unchanged full consolidated matrix, executable-manager scalability workload and privileged filesystem fixture. This is a corrective commit on the existing G branch, not final UX18-G acceptance or a change in the remaining strict history-dependent processing constraint.
- UX18-G.1: persistent generation catalog and V1–V4 migration/publication (locally qualified).
- UX18-G.2: sealed persistent historical integrity anchors, bounded on-demand historical ownership, safe ID arithmetic and removal of the 128-generation guard and generation-child lifetime bound; demonstrate more than 128 real generations with measured descriptor bounds (locally qualified).
- UX18-G.3: persistent receipt trie and cursor-aware search/pending/revision (locally qualified). Remaining engineering incorporated in G.4.
- UX18-G.4: catalog-backed ownership, streamed startup validation and bounded routine scrub candidate; strict full-history processing constraint and extended actual-manager target qualification remain explicit before closure.
The configured-location and session-notification limits are intentional. No destructive evidence retention is introduced. UX18-H, UX19 and UX20 retain their existing scope. The above was the pre-acceptance development plan; see final qualification below. None of the software requirements are physical testing deferrals.
Maintainer reports merge after all nine hosted checks and manual GUI review. The G.4.1 consolidated target run completed 274 PASS, 0 FAIL, 0 SKIPPED, 0 BLOCKED in 39m06s, including the exact target analyzer and installed systemd checks. The production-filesystem manager fixture retained 131 generations with 127 additional handoffs in 23.176s, sampled FD 12/12 and RSS 11820/11832 KiB. The operational baseline proceeds to UX18-H; strict admission readiness and explicit full-history checks remain history-dependent under the established integrity contract. This is not a claim of constant-time admission or arbitrary-history throughput.
Source repository · Documentation index · License policy
Documentation mirror — CC-BY-SA-4.0. KnetSentry is not an official KDE project.