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

feat: software upgrade proposal #ntrn-314 #20

Merged
merged 9 commits into from
Jan 15, 2023
37 changes: 18 additions & 19 deletions Cargo.lock

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

6 changes: 3 additions & 3 deletions artifacts/checksums.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
211577e38444ddee1c274195c68927c3564dba7b5734794ac74aac4925be8aac cwd_core.wasm
a7d0389f7ccddcd1833df91fd6005e249b1fbadb8048fc21a38b9bd259e54e9e cwd_pre_propose_single.wasm
9061ea45715d32747351251ec934a814654fd315ca76c24f57845ac9652a9557 cwd_proposal_single.wasm
8780b617252ebc3119f24bd6b0ad3d897547c93da017735f48ffc0c5268b90e5 cwd_core.wasm
46d597c43a510ed3b4aff3cb1fbe6f37981f2a39160c1247ba4bfc8f534f3b88 cwd_pre_propose_single.wasm
ff34f41a2599ecd7ce035322fb362e35feedee34d3a90b74e78809628fa191e7 cwd_proposal_single.wasm
d2336c2067b062d6e86e51dd58185e3a5b9fc84d41650c2c176f915106f9209c neutron_distribution.wasm
69f5a6ca7e74b555c2f4db0b979e98b61f2e36b8de7340b34d5cc011b0686704 neutron_reserve.wasm
b3b690c8ad6839c7772d2a50e88a14835c79d34791118a3600e4c09efff2e96d neutron_treasury.wasm
Expand Down
6 changes: 3 additions & 3 deletions artifacts/checksums_intermediate.txt
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
d1209871e9e55d01f556aac30d70610e9147f801e53183d554ddbb4503e5283f target/wasm32-unknown-unknown/release/cwd_core.wasm
ec098e437e1300a654bf5fa71ab82fd660670ef0c453f0d17429eafd45f001ef target/wasm32-unknown-unknown/release/cwd_pre_propose_single.wasm
e35349b7dcdc315c4e91cbafef9570c96adc06a11ce39ddfbde0a2cdc0355309 target/wasm32-unknown-unknown/release/cwd_proposal_single.wasm
b74ac8ee1b649d1fa671af9be078b7275c238d948b0d6078345bc254d906a2f3 target/wasm32-unknown-unknown/release/neutron_vault.wasm
0fcb3ab9c846845680e92e386b7b10468f047e1d52365c4b4f28cf71d62a7539 target/wasm32-unknown-unknown/release/neutron_voting_registry.wasm
e0d9d29377fe4f38c37c78b9a5c0615abb4920db90297a625b505564e323f90a target/wasm32-unknown-unknown/release/neutron_treasury.wasm
8783541318a2a8fe2babac48ff72a54d64c6ccb64c641169c50cf708b15d3296 target/wasm32-unknown-unknown/release/neutron_distribution.wasm
4283c2b225995033a6c5b90a2df518050593139cb11bf95e8cf5000c52539e0d target/wasm32-unknown-unknown/release/neutron_reserve.wasm
be244a1c723d4599fbbe67421f3add0a121b3c3434abe87abc4896b305291ef5 target/wasm32-unknown-unknown/release/cwd_core.wasm
a3dde205eb6274aeb86689a1147f134126b64fb0c470a2189ca439687b34b603 target/wasm32-unknown-unknown/release/cwd_pre_propose_single.wasm
455fb56027a0b4eff66520e2c0045c0ebdc8842529899e2607cbf2d56b076167 target/wasm32-unknown-unknown/release/cwd_proposal_single.wasm
Binary file modified artifacts/cwd_core.wasm
100644 → 100755
Binary file not shown.
Binary file modified artifacts/cwd_pre_propose_single.wasm
100644 → 100755
Binary file not shown.
Binary file modified artifacts/cwd_proposal_single.wasm
100644 → 100755
Binary file not shown.
2 changes: 1 addition & 1 deletion contracts/cwd-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ backtraces = ["cosmwasm-std/backtraces"]
library = []

[dependencies]
neutron_bindings = { package = "neutron-sdk", version = "0.1.0", git = "https://github.com/neutron-org/neutron-contracts.git" }
neutron_bindings = { package = "neutron-sdk", git = "https://github.com/neutron-org/neutron-sdk.git", rev = "8bfe55e549e683e36f44ccca7a22e94ae3fb47d8" }
cosmwasm-std = { version = "1.0.0", features = ["ibc3"] }
cosmwasm-storage = { version = "1.0.0" }
cw-storage-plus = "0.13"
Expand Down
66 changes: 64 additions & 2 deletions contracts/cwd-core/schema/execute_msg.json
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,17 @@
"type": "null"
}
]
},
"software_upgrade_proposal": {
"description": "*software_upgrade_proposal** is a software upgrade proposal field.",
"anyOf": [
{
"$ref": "#/definitions/SoftwareUpgradeProposal"
},
{
"type": "null"
}
]
}
}
},
Expand Down Expand Up @@ -781,7 +792,7 @@
]
},
"path": {
"description": "*path** is a path to the storage (storage prefix) where you want to read value by key (usually name of cosmos-sdk module: 'staking', 'bank', etc.)",
"description": "*path** is a path to the storage (storage prefix) where you want to read value by key (usually name of cosmos-packages module: 'staking', 'bank', etc.)",
"type": "string"
}
}
Expand Down Expand Up @@ -1140,7 +1151,7 @@
],
"properties": {
"description": {
"description": "*descriptionr** is a text description of proposal. Non unique.",
"description": "*description** is a text description of proposal. Non unique.",
"type": "string"
},
"param_changes": {
Expand All @@ -1156,6 +1167,30 @@
}
}
},
"Plan": {
"description": "Plan defines the struct for planned upgrade.",
"type": "object",
"required": [
"height",
"info",
"name"
],
"properties": {
"height": {
"description": "*height** is a height at which the upgrade must be performed",
"type": "integer",
"format": "int64"
},
"info": {
"description": "*info** is any application specific upgrade info to be included on-chain",
"type": "string"
},
"name": {
"description": "*name** is a name for the upgrade",
"type": "string"
}
}
},
"ProtobufAny": {
"description": "Type for wrapping any protobuf message",
"type": "object",
Expand Down Expand Up @@ -1199,6 +1234,33 @@
}
}
},
"SoftwareUpgradeProposal": {
"description": "SoftwareUpgradeProposal defines the struct for software upgrade proposal.",
"type": "object",
"required": [
"description",
"plan",
"title"
],
"properties": {
"description": {
"description": "*description** is a text description of proposal. Non unique.",
"type": "string"
},
"plan": {
"description": "*plan** is a plan of upgrade.",
"allOf": [
{
"$ref": "#/definitions/Plan"
}
]
},
"title": {
"description": "*title** is a text title of proposal. Non unique.",
"type": "string"
}
}
},
"StakingMsg": {
"description": "The message types of the staking module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.40.0/proto/cosmos/staking/v1beta1/tx.proto",
"oneOf": [
Expand Down
2 changes: 1 addition & 1 deletion contracts/pre-propose/cwd-pre-propose-single/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ cosmwasm-std = "1.0.0"
cw2 = "0.13.2"
serde = { version = "1.0.147", default-features = false, features = ["derive"] }
cwd-pre-propose-base = { version = "*", path = "../../../packages/cwd-pre-propose-base" }
neutron_bindings = { package = "neutron-sdk", version = "0.1.0", git = "https://github.com/neutron-org/neutron-contracts.git" }
neutron_bindings = { package = "neutron-sdk", git = "https://github.com/neutron-org/neutron-sdk.git", rev = "8bfe55e549e683e36f44ccca7a22e94ae3fb47d8" }
schemars = "0.8.8"

[dev-dependencies]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,17 @@
"type": "null"
}
]
},
"software_upgrade_proposal": {
"description": "*software_upgrade_proposal** is a software upgrade proposal field.",
"anyOf": [
{
"$ref": "#/definitions/SoftwareUpgradeProposal"
},
{
"type": "null"
}
]
}
}
},
Expand Down Expand Up @@ -684,7 +695,7 @@
]
},
"path": {
"description": "*path** is a path to the storage (storage prefix) where you want to read value by key (usually name of cosmos-sdk module: 'staking', 'bank', etc.)",
"description": "*path** is a path to the storage (storage prefix) where you want to read value by key (usually name of cosmos-packages module: 'staking', 'bank', etc.)",
"type": "string"
}
}
Expand Down Expand Up @@ -1003,7 +1014,7 @@
],
"properties": {
"description": {
"description": "*descriptionr** is a text description of proposal. Non unique.",
"description": "*description** is a text description of proposal. Non unique.",
"type": "string"
},
"param_changes": {
Expand All @@ -1019,6 +1030,30 @@
}
}
},
"Plan": {
"description": "Plan defines the struct for planned upgrade.",
"type": "object",
"required": [
"height",
"info",
"name"
],
"properties": {
"height": {
"description": "*height** is a height at which the upgrade must be performed",
"type": "integer",
"format": "int64"
},
"info": {
"description": "*info** is any application specific upgrade info to be included on-chain",
"type": "string"
},
"name": {
"description": "*name** is a name for the upgrade",
"type": "string"
}
}
},
"ProposeMessage": {
"oneOf": [
{
Expand Down Expand Up @@ -1097,6 +1132,33 @@
}
}
},
"SoftwareUpgradeProposal": {
"description": "SoftwareUpgradeProposal defines the struct for software upgrade proposal.",
"type": "object",
"required": [
"description",
"plan",
"title"
],
"properties": {
"description": {
"description": "*description** is a text description of proposal. Non unique.",
"type": "string"
},
"plan": {
"description": "*plan** is a plan of upgrade.",
"allOf": [
{
"$ref": "#/definitions/Plan"
}
]
},
"title": {
"description": "*title** is a text title of proposal. Non unique.",
"type": "string"
}
}
},
"StakingMsg": {
"description": "The message types of the staking module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.40.0/proto/cosmos/staking/v1beta1/tx.proto",
"oneOf": [
Expand Down
2 changes: 1 addition & 1 deletion contracts/proposal/cwd-proposal-single/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ backtraces = ["cosmwasm-std/backtraces"]
library = []

[dependencies]
neutron_bindings = { package = "neutron-sdk", git = "https://github.com/neutron-org/neutron-contracts.git" }
neutron_bindings = { package = "neutron-sdk", git = "https://github.com/neutron-org/neutron-sdk.git", rev = "8bfe55e549e683e36f44ccca7a22e94ae3fb47d8" }
cosmwasm-std = { version = "1.0.0", features = ["ibc3"] }
cosmwasm-storage = { version = "1.0.0" }
cw-storage-plus = "0.13"
Expand Down
Loading