Skip to content
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

fix: generate well-formed finalSaplingRoot in Arbitrary implementation #3573

Merged
merged 2 commits into from
Feb 17, 2022

Conversation

conradoplg
Copy link
Collaborator

Motivation

In #3544 we added a missing validation for the block commitments pre-Heartwood, when it's the Sapling note commitment tree root. It must be in the correct range.

However, this made a test fail since the Arbitrary implementation did not generate well-formed values, and the PR ended up being accidentally merged.

Specifications

Designs

Solution

  • Use a fixed "1" value which is well-formed.

I just noticed the issue so I didn't create an issue for it.

Review

Anyone can review. It's urgent because it makes all test flows after #3544 merged to fail.

Reviewer Checklist

  • Code implements Specs and Designs
  • Tests for Expected Behaviour
  • Tests for Errors

Follow Up Work

@conradoplg conradoplg requested a review from a team February 17, 2022 16:53
Copy link
Contributor

@oxarbitrage oxarbitrage left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find, thank you!

@codecov
Copy link

codecov bot commented Feb 17, 2022

Codecov Report

Merging #3573 (56aac6f) into main (499ae89) will increase coverage by 1.97%.
The diff coverage is 79.38%.

@@            Coverage Diff             @@
##             main    #3573      +/-   ##
==========================================
+ Coverage   78.34%   80.31%   +1.97%     
==========================================
  Files         267      276       +9     
  Lines       31526    32251     +725     
==========================================
+ Hits        24698    25902    +1204     
+ Misses       6828     6349     -479     

@mergify mergify bot merged commit bb232cc into main Feb 17, 2022
@mergify mergify bot deleted the fix-fake-heights-test branch February 17, 2022 20: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.

2 participants