Skip to content

Commit

Permalink
feat: export wallet types
Browse files Browse the repository at this point in the history
This commit re-exports the types required for a wallet interface, and
also requires `serde` for the `crates/rollup/stf` outside native as it
will be needed for JSON runtime call deserialization.
  • Loading branch information
vlopes11 committed Nov 20, 2023
1 parent 4c6543e commit 7df667c
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 6 deletions.
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 16 additions & 0 deletions crates/provers/risc0/guest-celestia/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/provers/risc0/guest-mock/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 10 additions & 2 deletions crates/stf/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ sov-state = { workspace = true }
sov-accounts = { workspace = true }
sov-bank = { workspace = true }
sov-sequencer-registry = { workspace = true }
sov-mock-da = { workspace = true }
sov-modules-stf-blueprint = { workspace = true }
sov-stf-runner = { workspace = true }
sov-sequencer = { workspace = true, optional = true }
Expand All @@ -31,16 +32,23 @@ clap = { workspace = true, features = ["derive"], optional = true }


[features]
default = []
default = ["serde"]
native = [
"sov-modules-api/native",
"sov-accounts/native",
"sov-bank/native",
"sov-sequencer-registry/native",
"sov-mock-da/native",
"sov-modules-stf-blueprint/native",
"sov-stf-runner/native",
"serde_json",
"jsonrpsee",
"sov-sequencer",
"clap",
]
]
serde = [
"sov-accounts/serde",
"sov-bank/serde",
"sov-modules-api/serde",
"sov-sequencer-registry/serde",
]
2 changes: 2 additions & 0 deletions crates/stf/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@ use sov_stf_runner::verifier::StateTransitionVerifier;
/// Alias for StateTransitionVerifier.
pub type StfVerifier<DA, Vm, ZkContext, RT, K> =
StateTransitionVerifier<StfBlueprint<ZkContext, <DA as DaVerifier>::Spec, Vm, RT, K>, DA, Vm>;

pub use sov_mock_da::MockDaSpec;
5 changes: 1 addition & 4 deletions crates/stf/src/runtime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,7 @@ use crate::genesis_config::GenesisPaths;
)]
#[derive(Genesis, DispatchCall, MessageCodec, DefaultRuntime)]
#[serialization(borsh::BorshDeserialize, borsh::BorshSerialize)]
#[cfg_attr(
feature = "native",
serialization(serde::Serialize, serde::Deserialize)
)]
#[cfg_attr(feature = "serde", serialization(serde::Serialize, serde::Deserialize))]
pub struct Runtime<C: Context, Da: DaSpec> {
/// The `accounts` module is responsible for managing user accounts and their nonces
pub accounts: sov_accounts::Accounts<C>,
Expand Down

0 comments on commit 7df667c

Please sign in to comment.