Skip to content

Integrate with ferveo crate#53

Merged
piotr-roslaniec merged 12 commits intonucypher:mainfrom
piotr-roslaniec:ferveo-types
May 29, 2023
Merged

Integrate with ferveo crate#53
piotr-roslaniec merged 12 commits intonucypher:mainfrom
piotr-roslaniec:ferveo-types

Conversation

@piotr-roslaniec
Copy link
Copy Markdown
Contributor

@piotr-roslaniec piotr-roslaniec commented May 22, 2023

@fjarri
Copy link
Copy Markdown
Contributor

fjarri commented May 22, 2023

Is it possible to make submodules somehow? Is it a thing in JS?

@piotr-roslaniec
Copy link
Copy Markdown
Contributor Author

Yes, you can implement modules in JS. For example, you can group your exports like this:

// my-module.js
export { MyClass, myFunction };

// run.js
import myModule from 'myModule'
myModule.myFunction();
const { MyClass } = myModule;

I'm not sure how to do it in nucypher-core-wasm yet, but I will give it a go.

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 23, 2023

Codecov Report

Merging #53 (a4f4575) into main (03b7ba0) will increase coverage by 0.01%.
The diff coverage is 28.00%.

@@            Coverage Diff             @@
##             main      #53      +/-   ##
==========================================
+ Coverage   15.24%   15.25%   +0.01%     
==========================================
  Files          16       16              
  Lines        2841     2845       +4     
==========================================
+ Hits          433      434       +1     
- Misses       2408     2411       +3     
Impacted Files Coverage Δ
nucypher-core-python/src/lib.rs 0.11% <0.00%> (-0.01%) ⬇️
nucypher-core-wasm/src/lib.rs 0.12% <0.00%> (ø)
nucypher-core/src/lib.rs 100.00% <ø> (ø)
nucypher-core/src/node_metadata.rs 0.00% <ø> (ø)
nucypher-core/src/dkg.rs 92.53% <100.00%> (+0.03%) ⬆️

@piotr-roslaniec
Copy link
Copy Markdown
Contributor Author

halp

@piotr-roslaniec
Copy link
Copy Markdown
Contributor Author

Ok, I just realized this is a known issue:
https://github.com/fjarri/wasm-bindgen-derive/blame/955ed47bef0806fc5eb08a9d011f4bce10b7cf16/wasm-bindgen-derive/src/lib.rs#L269

Should be fixed by updating wasm-bindgen-derive and wasm-bindgen consistently across all Rust crates.

@piotr-roslaniec
Copy link
Copy Markdown
Contributor Author

Hi @derekpierre, just wanted to check in with you. Are there any other TODOs that should be covered here?

@derekpierre
Copy link
Copy Markdown
Member

derekpierre commented May 25, 2023

Hi @derekpierre, just wanted to check in with you. Are there any other TODOs that should be covered here?

Perhaps this one as well? https://github.com/piotr-roslaniec/nucypher-core/blob/ferveo-types/nucypher-core/src/lib.rs#L51. Also adding @KPrasch as a reviewer.

--

Do these changes need an related update on the nucypher/nucypher python side of things?

@derekpierre derekpierre requested review from KPrasch and fjarri May 25, 2023 13:06
@piotr-roslaniec piotr-roslaniec marked this pull request as ready for review May 25, 2023 16:28
ritual_id: u16,
variant: u8,
ciphertext: &[u8], // TODO use ferveo Ciphertext type
ciphertext: &Ciphertext,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This change is supremely satisfying to see!

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

💯

Copy link
Copy Markdown
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.

🎸

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

Labels

None yet

Projects

Status: Completed

Development

Successfully merging this pull request may close these issues.

Integrate and re-export ferveo for public API

5 participants