Skip to content

Match Bitcoin Core v31 breaking changes, add SRI integration test#65

Draft
Sjors wants to merge 4 commits intostratum-mining:masterfrom
Sjors:2025/11/context
Draft

Match Bitcoin Core v31 breaking changes, add SRI integration test#65
Sjors wants to merge 4 commits intostratum-mining:masterfrom
Sjors:2025/11/context

Conversation

@Sjors
Copy link
Collaborator

@Sjors Sjors commented Nov 24, 2025

Can be done after:

This is a breaking change. Documentation is updated to explain how to use it (once the Bitcoin Core PR is merged).

@Sjors
Copy link
Collaborator Author

Sjors commented Nov 25, 2025

Note to self: bump the minor release version for this breaking change

@Sjors Sjors changed the title Pass missing context to createNewBlock() and checkBlock() Match Bitcoin Core v31 breaking changes Feb 17, 2026
@Sjors
Copy link
Collaborator Author

Sjors commented Feb 17, 2026

I'll update this with the other v31 breaking changes once bitcoin/bitcoin#34568 is merged.

Sjors added 3 commits March 20, 2026 16:31
Align sv2-tp's IPC interface definitions with Bitcoin Core
v31.

Move Init::makeMining to ordinal 3, leave ordinal 2 as an
internal assertion trap, add the createNewBlock context and
cooldown arguments plus the interrupt method, and remove the
old BlockTemplate coinbase accessors.

Switch sv2-tp to the CoinbaseTx-only path. Dropping the
signet witness-commitment check is safe because Bitcoin Core
populates required_outputs only after
GenerateCoinbaseCommitment() has added the witness commitment
when needed.

Also document that v1.0.6 is the last release compatible with
Bitcoin Core v30.2.

Assisted-by: OpenAI GPT-5-Codex
Call Mining::interrupt() during Template Provider shutdown
so createNewBlock() and waitTipChanged() can exit promptly
when Bitcoin Core's cooldown path is blocking.

This complements BlockTemplate::interruptWait(), which only
covers waits on already-created templates.

Assisted-by: OpenAI GPT-5-Codex
Only document a regtest setup using the native sv2 CPU miner. Leave more complicated setups, like an ASIC on testnet4, to the SRI docs.
@Sjors Sjors force-pushed the 2025/11/context branch from bb7d5a4 to e303364 Compare March 20, 2026 15:58
@Sjors
Copy link
Collaborator Author

Sjors commented Mar 20, 2026

Updated to include the full set of breaking changes for 31.x.

I also updated the testing guide, in particular to reflect that sv2-apps has a working sv2 native CPU miner, which makes it a lot easier.

@Sjors
Copy link
Collaborator Author

Sjors commented Mar 20, 2026

I turned the doc/stratum-v2.md scenario into an integration test.

@Sjors Sjors changed the title Match Bitcoin Core v31 breaking changes Match Bitcoin Core v31 breaking changes, add SRI integration test Mar 20, 2026
@Sjors Sjors force-pushed the 2025/11/context branch from 6675656 to d19afac Compare March 20, 2026 16:41
@Sjors Sjors force-pushed the 2025/11/context branch 3 times, most recently from 97f2a47 to 3592101 Compare March 20, 2026 17:45
Add a GitHub Actions job that downloads Bitcoin Core
v31.0rc1, builds sv2-tp plus the pool and miner binaries
from sv2-apps main, and runs the documented regtest
scenario.

Use actions-rust-lang/setup-rust-toolchain to match the
existing bitcoin-capnp-types project lead.

Assisted-by: OpenAI GPT-5 Codex
@Sjors Sjors force-pushed the 2025/11/context branch from 3592101 to b7294fa Compare March 20, 2026 17:59
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