Skip to content

excess_data: exclude the coinbase witness - #241

Open
Sjors wants to merge 1 commit into
stratum-mining:mainfrom
Sjors:2026/10/excess-data-no-witness
Open

Sjors wants to merge 1 commit into
stratum-mining:mainfrom
Sjors:2026/10/excess-data-no-witness

Conversation

@Sjors

@Sjors Sjors commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

The proposed NewTemplate.coinbase_witness field in #198 is intended to provide this information explicitly.

The current SRI template provider in sv2-apps already sends empty excess_data.

sv2-tp sends the coinbase witness instead, which causes problems, stratum-mining/sv2-tp#138.

Explicitly exclude the coinbase witness from excess_data and require the field to be empty for now. Keep the field and require Job Declarators to forward it unchanged.

The proposed NewTemplate.coinbase_witness field in stratum-mining#198 is intended to
provide this information explicitly.

The current SRI template provider in sv2-apps already sends empty
excess_data. sv2-tp sends the coinbase witness instead, which causes
problems discussed in stratum-mining/sv2-tp#138.

Explicitly exclude the coinbase witness from excess_data and require the
field to be empty for now. Keep the field and require Job Declarators to
forward it unchanged.
@Sjors

Sjors commented Oct 28, 2026

Copy link
Copy Markdown
Contributor Author

cc @plebhash and @TheBlueMatt

@plebhash

Copy link
Copy Markdown
Member

I'll dive into this soon @Sjors

currently I'm focusing on getting consensus around #234, which hopefully will happen later this week and get merged soon

once that's out of the way I'll come back to the excess_data / coinbase_witness discussions

Sjors added a commit to Sjors/sv2-tp that referenced this pull request Oct 29, 2026
No excess data is currently defined, and the coinbase witness does not
belong in this field. Always send empty excess_data, as proposed in:
stratum-mining/sv2-spec#241

This also avoids reading the coinbase after a submitted solution has
replaced it with a transaction that may have no inputs, fixing the crash
described in stratum-mining#138.
Sjors added a commit to stratum-mining/sv2-tp that referenced this pull request Nov 11, 2026
a32129b test: cover transaction requests after an inputless coinbase (Sjors Provoost)
6fa70e6 sv2: leave transaction response excess_data empty (Sjors Provoost)
4d6920d test: retain submitted coinbases in the mining mock (Sjors Provoost)

Pull request description:

  Depends on:
  - stratum-mining/sv2-spec#241

  The SRI version already does this.

  Alternative to #138.

ACKs for top commit:
  xyephy:
    tACK a32129b

Tree-SHA512: 1b788dda5e490f4d9a75ff341395ff6b45013f87aa5a0600fb2dbef1e0bb35af9dfdd0c6872e57d0f3ea374c38db3e519e0c3b84843e49062a42a56786444052
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.

2 participants