Skip to content

Conversation

@piotr-roslaniec
Copy link
Contributor

@piotr-roslaniec piotr-roslaniec commented Aug 25, 2023

Type of PR:

  • Other

Required reviews:

  • 1

What this does:

  • Avoids unwrap(), and handles errors gracefully instead
  • Replaces PartialEq impl. with a derive macro
  • Also throwing in a commit to address changes in the new Rust stable (1.7.2)

Issues fixed/closed:

  • Fixes #...

Why it's needed:

Explain how this PR fits in the greater context of the NuCypher Network.
E.g., if this PR address a nucypher/productdev issue, let reviewers know!

Notes for reviewers:

@codecov-commenter
Copy link

codecov-commenter commented Aug 25, 2023

Codecov Report

Merging #77 (5cfbc58) into main (43f943e) will increase coverage by 0.01%.
The diff coverage is 45.94%.

@@            Coverage Diff             @@
##             main      #77      +/-   ##
==========================================
+ Coverage   23.38%   23.40%   +0.01%     
==========================================
  Files          18       18              
  Lines        3540     3547       +7     
==========================================
+ Hits          828      830       +2     
- Misses       2712     2717       +5     
Files Changed Coverage Δ
nucypher-core-python/src/lib.rs 0.00% <0.00%> (ø)
nucypher-core-wasm/src/lib.rs 0.00% <0.00%> (ø)
nucypher-core/src/threshold_message_kit.rs 82.45% <66.66%> (+1.75%) ⬆️
nucypher-core/src/access_control.rs 87.17% <93.75%> (+0.11%) ⬆️

@piotr-roslaniec piotr-roslaniec marked this pull request as ready for review August 25, 2023 11:44
@piotr-roslaniec piotr-roslaniec added the do not merge Reviews are welcome, but please do not merge label Aug 25, 2023
@piotr-roslaniec piotr-roslaniec self-assigned this Aug 25, 2023
@piotr-roslaniec piotr-roslaniec mentioned this pull request Aug 25, 2023
7 tasks
@KPrasch
Copy link
Member

KPrasch commented Aug 27, 2023

rebased @ 43f943e (@piotr-roslaniec)

pub conditions: Option<Conditions>,
}

impl Eq for AuthenticatedData {}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does it work if you just add it to the list in #[derive]?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not quite. We'd also need to #[derive(Eq)] for DkgPublicKey in ferveo

Copy link

@manumonti manumonti left a comment

Choose a reason for hiding this comment

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

Not a rust developer, but looks good. ✌️

Copy link
Member

@derekpierre derekpierre left a comment

Choose a reason for hiding this comment

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

Nice work! Thanks for taking care of this.

Ok(Self(nucypher_core::ReencryptionResponse::new(
signer.as_ref(),
backend_capsules.iter().zip(backend_vcfrags.into_iter()),
backend_capsules.iter().zip(backend_vcfrags),
Copy link
Member

Choose a reason for hiding this comment

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

@piotr-roslaniec Let's be careful changing old PRE code unless necessary.

Is it that into_iter() no longer works, or is zip(...) just best practice?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do not merge Reviews are welcome, but please do not merge

Projects

Status: Completed

Development

Successfully merging this pull request may close these issues.

6 participants