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

WEB3-66: Add version string to RiscZeroGroth16Verifier.sol #187

Merged
merged 3 commits into from
Aug 7, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

<!-- TODO: Write a script (e.g. in Python) to automate as many of these steps as possible. -->
* Bump the version of all crates in the workspace to `x.y.z`. Workspace crate versions are specified in `./Cargo.toml`.
* Update the version string in contracts that contain it:
* `contracts/src/groth16/RiscZeroGroth16Verifier.sol`
* Remove the note at the top of `README.md` about being on the `main` branch.
* Update `risc0` crate dependencies. In all workspaces:
> You can find the workspaces with `grep -R '\[workspace\]' --include Cargo.toml -l .`
Expand All @@ -19,7 +21,10 @@
* Run `cargo update`.
* Remove `Cargo.lock` from `.gitignore` and commit all lock files.

* The other PR should bump the version on the `main` branch to the next, unreleased, minor version `x.y+1.0-alpha.1`.
* The other PR should:
* Bump the version on the `main` branch to the next, unreleased, minor version `x.y+1.0-alpha.1`.
* Update the version string in contracts that contain it:
* `contracts/src/groth16/RiscZeroGroth16Verifier.sol`

3. Tag the release as `vX.Y.Z`, and add release on GitHub.

Expand Down
3 changes: 3 additions & 0 deletions contracts/src/groth16/RiscZeroGroth16Verifier.sol
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ contract RiscZeroGroth16Verifier is IRiscZeroVerifier, Groth16Verifier {
using OutputLib for Output;
using SafeCast for uint256;

/// Semantic version of the the RISC Zero system of which this contract is part.
string constant VERSION = "1.1.0-alpha.1";
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder though, let's say no changes in the verifier contract between x.x.0 and x.x.5 are required, does that mean the deployed contract will keep an older version than the latest crate version?

Copy link
Contributor Author

@nategraf nategraf Aug 7, 2024

Choose a reason for hiding this comment

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

That's a good question. I think both changing it or not changing it is fine but I'm not sure which is better. Mostly it's there to make it easier to find the source code in GitHub when you are looking at the contract source in Etherscan.


/// @notice Control root hash binding the set of circuits in the RISC Zero system.
/// @dev This value controls what set of recursion programs (e.g. lift, join, resolve), and
/// therefore what version of the zkVM circuit, will be accepted by this contract. Each
Expand Down
Loading