Update Elements federation script and pegin address - #20
Merged
Conversation
Update MAINNET_FED_SCRIPT to the newly proposed federation script (proposed on-chain in block fe936658c04c22dba2f1df606b6f11041814f95c87e8ca302c62641d3da5b750). Compared to the previous script, the structure is unchanged (11-of-15 federation multisig with a 2-of-3 emergency fallback and identical emergency keys): 4 of the 15 federation pubkeys are rotated and the CSV emergency timeout is raised from 4032 to 8064 blocks. Regenerate the derived test fixtures accordingly: - expectedContract: pegin contract (HMAC-tweaked fedpegscript) for the fixture claim script, computed with the Elements contract-tweak algorithm and cross-checked against the previous fixture values - expected mainchain P2SH address, verified through the go-elements WASM MainChainAddress code path Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CQrBTWWVTXJCZHhDDeqzVL
tiero
marked this pull request as ready for review
July 27, 2026 12:04
The libwally Docker build broke because Debian buster reached EOL and its apt repositories moved to archive.debian.org, so every CI run failed at `make build` before running any tests. Point the buster image's apt sources at the archive (with Check-Valid-Until disabled, as the archived Release files are past their validity window) and drop the no-longer-served buster-updates entry. Also modernize the workflow: - Node 14.x/16.x matrix -> Node 22.x - actions/checkout@v2 -> v4, actions/setup-node@v1 -> v4 (both old versions run on a deprecated Node runtime) - replace bahmutov/npm-install with `npm ci` + setup-node's built-in npm cache Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CQrBTWWVTXJCZHhDDeqzVL
The lockfile entry for tiny-secp256k1 was missing the
"hasInstallScript" flag, so npm >= 7 does not run the package's own
guarded install script ("node-gyp rebuild || echo ..."), and instead
injects the default `node-gyp rebuild` because the package ships a
binding.gyp. The native build has always failed (nan 2.13 predates
modern V8) and is designed to fall back to the pure JS implementation,
but without the guard the failure aborts `npm ci`.
Setting the flag makes npm run the package's actual install script
again, restoring the non-fatal fallback behavior npm 6 had.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CQrBTWWVTXJCZHhDDeqzVL
The libwally image installs emscripten 2.0.9 but cloned emsdk master, whose installer scripts now require python >= 3.10 while buster ships 3.7. Clone the emsdk 2.0.9 tag instead so the installer scripts match the era of the toolchain being installed. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CQrBTWWVTXJCZHhDDeqzVL
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR updates the mainnet federation script and corresponding test fixtures to reflect changes in the Elements federation configuration.
Key Changes
Updated MAINNET_FED_SCRIPT: Modified the federation script in
src/index.tswith new public keys and adjusted script parametersc00fto801f(affecting the multisig requirements)Updated test fixtures:
expectedContractintest/fixtures/fixtures.tsto match the new federation scripttest/peginaddress.spec.tsfrom3AV836ASdCs6k25KjFweWxXNKyJdNx2tFhto3HfF9gFpqZPxfGe4rtwWD7nxFpvrL6xZq5Implementation Details
The changes appear to be related to a federation update on the Elements network, with modifications to the multisig script structure and the participating federation members' public keys. The test fixtures have been updated to ensure consistency with the new federation configuration.
https://claude.ai/code/session_01CQrBTWWVTXJCZHhDDeqzVL