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

Convert native node code from neon to napi-rs #947

Merged
merged 9 commits into from Feb 4, 2022
Merged

Convert native node code from neon to napi-rs #947

merged 9 commits into from Feb 4, 2022

Conversation

dguenther
Copy link
Member

Summary

napi-rs has a pretty convenient built-in system for generating prebuilt npm packages for Rust-based modules, plus has other features that would help us out (BigInt support, Promise support, automatically generating TS definitions and JS bindings). Since I'm working on generating prebuilt packages, I wanted to make this change first.

This is pretty likely to fail CI somewhere, so I'm putting this in draft until CI passes.

Testing Plan

I tried generating a transaction, mining, and syncing blocks from another node.

Breaking Change

This shouldn't break compatibility with other versions of the node, but it will require an upgrade of your Rust compiler if building from source.

[ ] Yes
[x] No

@dguenther dguenther marked this pull request as ready for review February 2, 2022 20:29
@dguenther dguenther requested a review from a team as a code owner February 2, 2022 20:29
@dguenther
Copy link
Member Author

Okay, I think this one is ready for review now. I'm going to skim it myself too to make sure nothing unexpected slipped in.

Copy link
Contributor

@mat-if mat-if left a comment

Choose a reason for hiding this comment

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

much nicer looking

ironfish-rust-nodejs/src/lib.rs Outdated Show resolved Hide resolved
@dguenther dguenther merged commit 9a38516 into staging Feb 4, 2022
@dguenther dguenther deleted the napi branch February 4, 2022 21:48
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.

None yet

2 participants