-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: migrate msgs to vrfdkgp for other contracts to use
- Loading branch information
1 parent
1f7f16b
commit f20a1de
Showing
12 changed files
with
73 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
[package] | ||
authors = ["Oraichain Labs"] | ||
edition = "2021" | ||
license = "AGPL-3.0" | ||
name = "vrfdkgp" | ||
version = "0.1.0" | ||
|
||
exclude = [ | ||
# Those files are rust-optimizer artifacts. You might want to commit them for convenience but they should not be part of the source code publication. | ||
"artifacts/", | ||
] | ||
|
||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | ||
|
||
[lib] | ||
crate-type = ["cdylib", "rlib"] | ||
|
||
[features] | ||
# use library feature to disable all instantiate/execute/query exports | ||
library = [] | ||
# for quicker tests, cargo test --lib | ||
# for more explicit tests, cargo test --features=backtraces | ||
backtraces = ["cosmwasm-std/backtraces"] | ||
|
||
[dependencies] | ||
cosmwasm-std = { version = "1.5" } | ||
cosmwasm-schema = { version = "1.5" } | ||
schemars = "0.8" | ||
serde = { version = "1.0.204", default-features = false, features = ["derive"] } | ||
thiserror = "1.0" | ||
cw-utils = { workspace = true } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[dependencies] | ||
std = { default-features = false } |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
pub mod errors; | ||
pub mod msg; | ||
pub mod state; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
use cosmwasm_schema::cw_serde; | ||
use cosmwasm_std::Coin; | ||
|
||
use crate::msg::SharedStatus; | ||
|
||
#[cw_serde] | ||
pub struct Config { | ||
/// The denom in which bounties are paid. This is typically the fee token of the chain. | ||
pub total: u16, | ||
pub threshold: u16, | ||
pub dealer: u16, | ||
// total dealers and rows have been shared | ||
pub shared_dealer: u16, | ||
pub shared_row: u16, | ||
pub fee: Option<Coin>, | ||
pub status: SharedStatus, | ||
} | ||
|
||
#[cw_serde] | ||
pub struct Owner { | ||
pub owner: String, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
pub mod contract; | ||
pub mod errors; | ||
pub mod msg; | ||
pub mod state; | ||
|
||
#[cfg(test)] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,11 @@ | ||
use cosmwasm_schema::cw_serde; | ||
use cw_storage_plus::{Item, Map}; | ||
|
||
use cosmwasm_std::Coin; | ||
use vrfdkgp::{ | ||
msg::{DistributedShareData, Member}, | ||
state::{Config, Owner}, | ||
}; | ||
|
||
pub const CONFIG: Item<Config> = Item::new("config"); | ||
pub const ROUND_COUNT: Item<u64> = Item::new("round_count"); | ||
pub const OWNER: Item<Owner> = Item::new("owner"); | ||
pub const MEMBERS: Map<&[u8], Member> = Map::new("members"); | ||
pub const BEACONS: Map<&[u8], DistributedShareData> = Map::new("beacons"); | ||
|
||
use crate::msg::{DistributedShareData, Member, SharedStatus}; | ||
|
||
#[cw_serde] | ||
pub struct Config { | ||
/// The denom in which bounties are paid. This is typically the fee token of the chain. | ||
pub total: u16, | ||
pub threshold: u16, | ||
pub dealer: u16, | ||
// total dealers and rows have been shared | ||
pub shared_dealer: u16, | ||
pub shared_row: u16, | ||
pub fee: Option<Coin>, | ||
pub status: SharedStatus, | ||
} | ||
|
||
#[cw_serde] | ||
pub struct Owner { | ||
pub owner: String, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters