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

Stacks.rs (Stacks Library for Rust) #4

Closed
will-corcoran opened this issue Mar 21, 2023 · 12 comments
Closed

Stacks.rs (Stacks Library for Rust) #4

will-corcoran opened this issue Mar 21, 2023 · 12 comments

Comments

@will-corcoran
Copy link
Contributor

will-corcoran commented Mar 21, 2023

Discussed in https://github.com/stacksgov/Stacks-Grant-Launchpad/discussions/854

Originally posted by will-at-stacks March 17, 2023

Introduction:

While sBTC is currently the mission-critical project within the Stacks ecosystem, it is important to also support the development of Stacks Libraries and SDKs. By doing so, developers fluent in various languages will be more compelled to contribute to Stacks projects.

Critical Bounty Mission Statement:

This Critical Bounty aims to support the development of a Stacks Rust Library. Its development will need to be done in conjunction with the Stacks Rust Library (also a 2023 Q2 Critical Bounty). The Stacks Rust Library should comply with either the Apache2 or MIT permissive licensing. Additionally, it cannot depend on any reference implementation for Stacks that is GPL-licensed.

Functionality / Deliverables (shall include, but not be limited to):

  • target WebAsm, in this case we can use the library in JavaScript, for example in stacks.js.
  • consistent serialization/deserialization Rust and JS ClarityValues into string (Clarity lang).
  • Rust library matching functionality of both microstacks and stacks.js.
  • Developer documentation deployed to docs.rs
  • Crate deployed to crates.io
  • Product 'roadshow', feedback, and improvements: All recipients will be responsible for demonstrating functionality, championing early adoption, gathering feedback, and making one to two rounds of high-impact, feedback-based improvements.

Required Knowledge / Skills:

  • Experience developing libraries in Rust.
  • Familiarity with Javascript and stacks.js

References:

  1. Clarinet Docs (reference for design system req’d for Typescript applications wrapped within a Rust application)
  2. TM Repo (code & documentation standard)
  3. Stacks.rs Discussion
  4. https://crates.io/crates/pyo3
  5. https://pypi.org/

Critical Bounty Fee:

  • Maximum Fee: $16,000

Reviewers / Advisors:

Igor Sylvester, Core Engineering Lead, Trust Machines
Mårten Blankfors, Core Engineer, Trust Machines
Sergey Shandar, Core Engineer, Trust Machines
Jesse Wiley, Integration and Security Lead, Stacks Foundation
Kenny Rogers, Developer Advocate, Stacks Foundation
Will Corcoran, Grants Lead, Stacks Foundation

Additional Comments:

Recipient will be expected to attend sBTC Core Engineering Working Group calls while the bounty is in development and provide weekly updates.

APPLY HERE


NOTES ABOUT CRITICAL BOUNTIES:

If you have thoughts, questions, or comments on the rough outline for this Critical Bounty above, please comments below.

Please note, all 2023 Q2 Critical Bounties that have funding approved for them will be moved to the Issues page (here) on Tuesday 03/21/2023.

Some procedural items to keep in mind with 2023 Q2 Critical Bounties:

  1. Each Critical Bounty will have a pre-approved minimum and maximum budget listed within the issue.
  2. All applications will be submitted via a BlockSurvey which will be linked within the Issue.
  3. Applications will be open from 03/21/2023 to 04/03/2023.
  4. Critical Bounty applications will be reviewed by relevant members of the sBTC Core Engineering Team and technical staff from the Stacks Foundation.
  5. The selected recipient will be the low, qualified bidder (in the eyes of the reviewers).
  6. Selected Critical Bounty recipients will be announced on 04/07/2023 and will be expected to start work immediately and attend sBTC Core Engineering meetings to provide weekly updates on their work.
@stacks-foundation
Copy link

👋 @will-at-stacks


Thanks for your application! We will do a pre-review and let you know if we have any immediate questions. In the mean time please refer to our review schedule here for a detailed timeline and response dates.


Best,
Will

@will-corcoran will-corcoran changed the title CB-23Q2-01.1 : Stacks.rs (Stacks Library for Rust) CB-2Q23-01.1 : Stacks.rs (Stacks Library for Rust) Mar 27, 2023
@diwakergupta
Copy link

@will-at-stacks @igorsyl I'm still not sure I understand exactly what is in scope for such a library, especially relative to something like https://github.com/hirosystems/stacks-encoding-native-js -- is there a more detailed scope description somewhere?

@igorsyl
Copy link

igorsyl commented Apr 10, 2023

@diwakergupta sBTC needs a Rust library with no js dependencies.

@diwakergupta
Copy link

@diwakergupta sBTC needs a Rust library with no js dependencies.

I get that, I was asking more about exactly what's the scope of this Rust library. Is there a doc that covers the required functionality?

@igorsyl
Copy link

igorsyl commented Apr 10, 2023

Yes, it's in this issue description.

@will-corcoran
Copy link
Contributor Author

@rswol Congrats on being awarded this Critical Bounty for $16k

More information on this Critical Bounty can be found here

@will-corcoran
Copy link
Contributor Author

@rswol please post your original application for the Critical Bounty here for public awareness.

Thanks,
Will

@lgalabru
Copy link

I'm also having a hard time understanding the scope of this lib.
Have you tried using https://crates.io/crates/clarity-vm?
This crate is being produced by this PR, that we should definitely wrap-up: stacks-network/stacks-core#3478.

@will-corcoran
Copy link
Contributor Author

will-corcoran commented May 2, 2023

I'm also having a hard time understanding the scope of this lib. Have you tried using https://crates.io/crates/clarity-vm? This crate is being produced by this PR, that we should definitely wrap-up: stacks-network/stacks-blockchain#3478.

@rswol thoughts?

@igorsyl
Copy link

igorsyl commented May 2, 2023

sBTC team needs to use stacks.js primitives from Rust and we rather not run an embedded JS VM.

@BowTiedDeployer
Copy link

BowTiedDeployer commented May 11, 2023

Degens team would also find this helpful. With methods to call following the same way as the stacks.js library, both for read-only and smart contract calls it would be easier and more efficient to develop.

The conversion to and from clarity values to the pramming language used ( js/rust ) is also very important. It is very straightforward to convert using stacks.js, by having well defined conversion methods. At the moment in rust it is a process in itself to find how to process the information to do the wanted operations and get the needed values in the right format.

@will-corcoran will-corcoran transferred this issue from stacksgov/grants-program Jun 21, 2024
@will-corcoran will-corcoran changed the title CB-2Q23-01.1 : Stacks.rs (Stacks Library for Rust) Stacks.rs (Stacks Library for Rust) Jun 21, 2024
@diwakergupta
Copy link

@will-corcoran is this actually completed? If yes, can you include pointers to the deliverables (the Rust create, link to docs, GH repo etc)?

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

No branches or pull requests

6 participants