Skip to content

Conversation

@plebhash
Copy link
Member

@plebhash plebhash commented Apr 4, 2025

@plebhash plebhash marked this pull request as draft April 4, 2025 16:38
@plebhash plebhash changed the title clarify new_shares_sum field of SubmitShares.Success [WIP] clarify new_shares_sum field of SubmitShares.Success Apr 4, 2025
@plebhash plebhash force-pushed the 2025-04-04-clarify-submit-shares-success branch 2 times, most recently from 87d8db6 to 8a56281 Compare April 9, 2025 21:40
@pavlenex
Copy link
Contributor

Thanks for adding these graphics, it makes things way easier to understand!

@plebhash plebhash force-pushed the 2025-04-04-clarify-submit-shares-success branch 2 times, most recently from 9f44b3b to 592112a Compare April 10, 2025 21:29
plebhash referenced this pull request in vinteumorg/pleblottery Jun 16, 2025
it's not clear what the `new_shares_sum` field of `SubmitShares.Success` really means

after reaching out to @jakubtrnka , he described the following:

> `new_submits_accepted_count` is number of submits.
> `new_shares_sum` is "integral" over difficulty of work to be confirmed by this success msg

this commit clarifies both `SubmitShares.Success` and `SubmitShares.Error` with detailed descriptions and new visual diagrams.
@plebhash
Copy link
Member Author

plebhash commented Oct 24, 2025

note:

I should take the opportunity of this PR to also clarify this:

| Field Name                 | Data Type | Description                                         |
| -------------------------- | --------- | --------------------------------------------------- |
| channel_id                 | U32       | Channel identification                              |
| last_sequence_number       | U32       | Most recent sequence number with a correct result   |
| new_submits_accepted_count | U32       | Count of new submits acknowledged within this batch |
| new_shares_sum             | U64       | Sum of difficulty of shares acknowledged within this batch        |

the description of new_submits_accepted_count and new_shares_sum is still a bit confusing to me

currently, when SRI sends a SubmitSharess.Success, it is doing something like:

  • Count of new submits acknowledged SO FAR, including this batch, not within this batch
  • Sum of difficulty of shares acknowledged SO FAR, including this batch, not within this batch

@plebhash
Copy link
Member Author

with regards to the comment above, I confirmed that SRI is currently incorrect

stratum-mining/stratum#1967

that should be fixed via stratum-mining/stratum#1968

@plebhash plebhash force-pushed the 2025-04-04-clarify-submit-shares-success branch from 592112a to ce15cb7 Compare October 24, 2025 21:10
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.

SubmitShares.Success has unclear description of new_shares_sum field

2 participants