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

Rename PrepareMessage to PrepareState #103

Merged
merged 2 commits into from
Oct 3, 2022
Merged

Conversation

jbr
Copy link
Contributor

@jbr jbr commented Sep 22, 2022

closes #31 based on #34

@jbr jbr force-pushed the prepare-message-to-prepare-state branch from c26fc05 to e890972 Compare September 22, 2022 22:24
Copy link
Collaborator

@divergentdave divergentdave left a comment

Choose a reason for hiding this comment

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

The type changes look good, but there are three method names that we should roll back, because they were correctly referring to prepare messages.

@@ -267,7 +267,7 @@ export class Prio3<Measurement> implements Prio3Vdaf<Measurement> {
return { verifier, jointRand };
}

private encodePrepareMessage(
private encodePrepareState(
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should keep the name encodePrepareMessage. (Technically, we are using this function to encode both prepare message shares and prepare messages, but these have the same concrete type and encoding in the context of Prio3)

@@ -242,7 +242,7 @@ export class Prio3<Measurement> implements Prio3Vdaf<Measurement> {
: await this.decodeHelperShare(aggregatorId, encoded);
}

private decodePrepareMessage(input: Buffer): {
private decodePrepareState(input: Buffer): {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Likewise, this should keep the name decodePrepareMessage.

| { outputShare: OutputShare };

prepSharesToPrepareMessage(
prepSharesToPrepareState(
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should keep the name prepSharesToPrepareMessage. See https://cfrg.github.io/draft-irtf-cfrg-vdaf/draft-irtf-cfrg-vdaf.html#section-5.2-6.3

@jbr jbr force-pushed the prepare-message-to-prepare-state branch 2 times, most recently from 20ff3d2 to 909303b Compare September 30, 2022 05:20
@coveralls
Copy link

coveralls commented Sep 30, 2022

Pull Request Test Coverage Report for Build 3161133892

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 10 of 11 (90.91%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 91.609%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/vdaf/src/index.ts 3 4 75.0%
Totals Coverage Status
Change from base Build 3161115950: 0.0%
Covered Lines: 978
Relevant Lines: 1038

💛 - Coveralls

@jbr jbr requested a review from divergentdave September 30, 2022 19:14
@jbr jbr force-pushed the prepare-message-to-prepare-state branch from 909303b to 2a48674 Compare September 30, 2022 19:19
Copy link
Collaborator

@divergentdave divergentdave left a comment

Choose a reason for hiding this comment

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

Looks good, I noted one more rename of a temporary below.

packages/prio3/src/prio3.ts Outdated Show resolved Hide resolved
Co-authored-by: David Cook <dcook@letsencrypt.org>
@jbr jbr merged commit f3840c9 into main Oct 3, 2022
@jbr jbr deleted the prepare-message-to-prepare-state branch October 3, 2022 22:26
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.

Rename PrepareMessage to PrepareState
3 participants