-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: document the start/end row in row proof #1473
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm pretty confused by the comment. Any chance it can be rephrased to clarify what it means?
types/row_proof.go
Outdated
// Note: it's currently not used for verification, only for validation. | ||
// If it's used downstream, make sure to validate it. | ||
StartRow uint32 `json:"start_row"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[question] can we please clarify "it" here? Is this correct? "it" is used four times but I think they mean different things.
// Note: it's currently not used for verification, only for validation. | |
// If it's used downstream, make sure to validate it. | |
StartRow uint32 `json:"start_row"` | |
// Note: StartRow is currently not used for verification, only for validation. | |
// Before using a RowProof, users are expected to call Validate(). | |
StartRow uint32 `json:"start_row"` |
If not, can we clarify this comment in another way?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
4f4c617 ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems better to me.
- What does "extra validation depending on how it's used." entail?
- Why would this field be unused downstream? It seems like a necessary component of RowProof.
Extra validation depends on how those fields are used. When verifying the inclusion of a set of rows to the data root, you don't necessarily need to know where they are. What you care about is that they're committed by the data root. This is done using the slice of proofs and row roots. |
Does any downstream repo use StartRow or EndRow to indicate anything besides the row range where the data is? It seems like these fields should only be used for that. If they're present they describe the row range.
Got it, thanks. |
Currently, no. But when building zk-vms that create/verify these proofs, some teams asked about the fields whether they need any specific constraints. That's why we're clarifying that in the comment + letting them know that if they have something specific in mind, they should think about their constraints |
CI fixed here: #1474 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added some comments/questions about some validation that can be relevant to the StartRow
and EndRow
.
Description
Adds a simple documentation to the start row and end row fields in row proof to show that they're not used for verification. But if anyone is using them downstream, they should validate them themselves