Skip to content

Release v0.23.0 - #14

Merged
jdogresorg merged 119 commits into
masterfrom
release/v0.23.0
Oct 12, 2026
Merged

jdogresorg merged 119 commits into
masterfrom
release/v0.23.0

Conversation

@jdogresorg

Copy link
Copy Markdown
Contributor

Brings master to the contracts the v0.23.0 train was tested against: develop at 1d06d50 plus the staged xchain-vm 0.23.0 lockfile record (9a8c4a7). The v0.23.0 combined matrix https://github.com/XChain-Platform/xchain-node/actions/runs/38198510195 ran with this tree bundled, and the xchain-sdk release templates match it.

Run the guard directly and require a clean exit with no stderr. Preserve regression coverage for both required xchain-vm files.
Use the snake_case test filename required by the repository structure ratchet.
Include the standalone guard test in the repository suite and synchronize the staged xchain-vm lock metadata with its sibling manifest.
Keep shared loading and mocks in the entry suite while registering validation, helper detection, guard behavior, bind hint, and metadata cases from focused modules.
Keep shared harness setup in the entry suite and register focused happy-path, attack, exact-custody, and deploy-validation test modules.
Extract responsibility-focused test registration modules while retaining shared harness setup in the entry suite.
Keep shared harness setup in the entry suite and register happy-path, attack, exact custody and payment, and deploy-validation cases from focused modules.
Preserve the public entry point while extracting validation, metadata, emission, and bind-hint responsibilities. Keep generated policy behavior and output unchanged.
Rename the extracted policy test registration modules to satisfy the repository file naming ratchet and update their entry-suite imports.
Keep shared harness setup in the entry suite and register focused modules for each behavioral area. Preserve the complete treasury test inventory.
Keep the extracted policy suites below the function-size ratchet by registering their existing cases through short responsibility helpers.
Keeps each registration function under the function-line limit.
Entry suite keeps shared setup; happy-path, oracle-window and timing attack, custody, numeric seam and deploy-validation cases move under price_bet_timed_test, each under 400 lines.
Move sendsPayload to module level and build the shared test context in a
module-level buildContext(), so the describe callback only registers the
test groups. Test titles and count (23) are unchanged.
The module export (87 lines) and the deploy-time validation describe
callback (80 lines) are split into per-topic registration helpers plus a
shared deployFresh helper. Test titles, order and assertions unchanged.
The module export (144 lines) and its 'happy paths' describe callback
(136 lines) are now four module-level registration helpers, each pulling
only the context names it uses, called in the original order from a short
describe callback. Test titles and order are unchanged.
Move the five happy path tests out of the 80-line module export and
72-line describe callback into two helpers, registerBiddingTests and
registerItemReturnTests. Test titles and bodies are unchanged.
registerEvictedRoundAttacks was 131 lines. Break it into four
registrars (scan reads, scan span, accept wedge, withheld tip) that
each destructure only what they use. Test titles and order unchanged.
The describe callback in lib/staged-sibling-advisories.test.js ran to 62
lines. Moving the package-lock.json root search into a module-level
findLockRoot() helper brings it to 54 lines. Test titles and assertions
are unchanged.
validateConfig was 148 lines. Move each key's validation into its own
helper (name, gates, freeze, allowlist, allowlistDirection, maxTakeBps,
royalty and its legs, permissions, owner). Helpers run in the original
order, so the first failing assertion, its message and the key order of
the returned config are unchanged. Every function is now under 60 lines.
Break the happy_paths, empty_token_info and fixed_notation_amounts
registrar callbacks into named per-group helpers so no function exceeds
60 lines. Test titles, bodies and order are unchanged.
emitSource was a single 149-line function. Break it into one helper per
section of the generated guard (header, constants, hoisted helpers,
export descriptors, initialize, admin methods, guard) plus a flags
resolver, each under 60 lines. Emitted source is byte-identical.
Lift the harness proxy and the deploy/oracle/settle helpers to module level and build the shared test context in a module-level buildContext(), so the describe callback only registers the test groups. Test titles and count are unchanged.
Lift the shared test context and the deploy/call/propose/arm helpers to module level, so the describe callback only registers the test groups. The register modules still read h and base off the shared context at test time. Test titles and count are unchanged.
Lift each nested describe into a module-level register function and the round-trip case body into settledRoundTrip(), so the top-level describe callback only sets up the VM and registers the groups. The shared vm moves to module scope and is still created in before(). Test titles and count are unchanged.
Lift the shared harness state (h, base) and the deploy/fund/atElapsed/claim
helpers to module scope, and move each nested describe into a module-level
register function, so the top-level describe callback only registers the
groups. badDeploy and deployOffGrid (with TOTAL8/DUR3) move to module scope
so the deploy-time validation and off-grid groups each fit under 60 lines.
Test bodies, titles, order and count (34) are unchanged.
Register each describe's tests from short named functions called in their original order, so every function is under 60 lines. The shared harness stays in the describe and registrars reach it through a context getter. Titles, nesting and order are unchanged.
The v0.23.0 release bumped xchain-vm to 0.23.0, but this package-lock still recorded the staged sibling at 0.21.3, so ADV-9 failed against the release sibling.
@jdogresorg
jdogresorg merged commit 84f2d68 into master Oct 12, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant