Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion .rustfmt.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
reorder_imports = true
hard_tabs = true
max_width = 120
wrap_comments = true
# wrap_comments = true
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.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ pallet-transaction-payment-rpc-runtime-api = { version = "41.0.0", default-featu
pallet-treasury = { version = "40.0.0", default-features = false }
pallet-utility = { version = "41.0.0", default-features = false }
pallet-vesting = { version = "41.0.0", default-features = false }
pallet-revive = {version = "=0.7.0", default-features = false }

# Cumulus client dependencies
cumulus-primitives-aura = { version = "0.18.0", default-features = false }
Expand Down
26 changes: 15 additions & 11 deletions runtime/kreivo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ pallet-preimage.workspace = true
pallet-proxy.workspace = true
pallet-ranked-collective.workspace = true
pallet-referenda.workspace = true
pallet-revive.workspace = true
pallet-scheduler.workspace = true
pallet-session.workspace = true
pallet-skip-feeless-payment.workspace = true
Expand Down Expand Up @@ -170,6 +171,7 @@ std = [
"pallet-ranked-collective/std",
"pallet-referenda/std",
"pallet-referenda-tracks/std",
"pallet-revive/std",
"pallet-scheduler/std",
"pallet-session/std",
"pallet-skip-feeless-payment/std",
Expand Down Expand Up @@ -251,6 +253,7 @@ runtime-benchmarks = [
"pallet-ranked-collective/runtime-benchmarks",
"pallet-referenda/runtime-benchmarks",
"pallet-referenda-tracks/runtime-benchmarks",
"pallet-revive/runtime-benchmarks",
"pallet-scheduler/runtime-benchmarks",
"pallet-skip-feeless-payment/runtime-benchmarks",
"pallet-sudo/runtime-benchmarks",
Expand Down Expand Up @@ -282,6 +285,7 @@ runtime-benchmarks = [
]

try-runtime = [
"assets-common/try-runtime",
"cumulus-pallet-aura-ext/try-runtime",
"cumulus-pallet-parachain-system/try-runtime",
"cumulus-pallet-xcm/try-runtime",
Expand All @@ -291,26 +295,32 @@ try-runtime = [
"frame-support/try-runtime",
"frame-try-runtime/try-runtime",
"pallet-assets-freezer/try-runtime",
"pallet-assets-holder/try-runtime",
"pallet-asset-tx-payment/try-runtime",
"pallet-assets/try-runtime",
"pallet-aura/try-runtime",
"pallet-authorship/try-runtime",
"pallet-balances/try-runtime",
"pallet-black-hole/try-runtime",
"pallet-contracts/try-runtime",
"pallet-contracts-store/try-runtime",
"pallet-communities-manager/try-runtime",
"pallet-communities/try-runtime",
"pallet-collator-selection/try-runtime",
"pallet-gas-transaction-payment/try-runtime",
"pallet-listings/try-runtime",
"pallet-message-queue/try-runtime",
"pallet-nfts/try-runtime",
"pallet-multisig/try-runtime",
"pallet-orders/try-runtime",
"pallet-pass/try-runtime",
"pallet-payments/try-runtime",
"pallet-preimage/try-runtime",
"pallet-proxy/try-runtime",
"pallet-ranked-collective/try-runtime",
"pallet-referenda/try-runtime",
"pallet-referenda-tracks/try-runtime",
"pallet-revive/try-runtime",
"pallet-scheduler/try-runtime",
"pallet-session/try-runtime",
"pallet-skip-feeless-payment/try-runtime",
Expand All @@ -319,19 +329,13 @@ try-runtime = [
"pallet-transaction-payment/try-runtime",
"pallet-treasury/try-runtime",
"pallet-utility/try-runtime",
"pallet-vesting/try-runtime",
"pallet-xcm/try-runtime",
"pass-webauthn/try-runtime",
"parachains-common/try-runtime",
"parachain-info/try-runtime",
"pass-substrate-keys/try-runtime",
"pass-webauthn/try-runtime",
"polkadot-runtime-common/try-runtime",
"runtime-common/try-runtime",
"sp-runtime/try-runtime",
"pallet-listings/try-runtime",
"pallet-vesting/try-runtime",
"pallet-assets-holder/try-runtime",
"pallet-orders/try-runtime",
"pallet-contracts-store/try-runtime",
"pass-substrate-keys/try-runtime",
"pallet-black-hole/try-runtime",
"assets-common/try-runtime",
"parachains-common/try-runtime"
"sp-runtime/try-runtime"
]
1 change: 1 addition & 0 deletions runtime/kreivo/src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ pub mod governance;
pub mod contracts;
mod listings_orders;
pub mod payments;
pub mod revive;

pub use {
collator_support::{ConsensusHook, SLOT_DURATION},
Expand Down
33 changes: 33 additions & 0 deletions runtime/kreivo/src/config/revive/mod.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
use super::*;
use frame_system::EnsureRootWithSuccess;

parameter_types! {
pub const DepositPerItem: Balance = deposit(1, 0);
pub const DepositPerByte: Balance = deposit(0, 1);
pub CodeHashLockupDepositPercent: Perbill = Perbill::from_percent(30);
pub const ChainId: u64 = 2281;
}

impl pallet_revive::Config for Runtime {
type Time = Timestamp;
type Currency = Balances;
type RuntimeEvent = RuntimeEvent;
type RuntimeCall = RuntimeCall;
type DepositPerItem = DepositPerItem;
type DepositPerByte = DepositPerByte;
type WeightPrice = pallet_transaction_payment::Pallet<Self>;
type WeightInfo = pallet_revive::weights::SubstrateWeight<Self>;
type Precompiles = ();
type AddressMapper = pallet_revive::AccountId32Mapper<Self>;
type RuntimeMemory = ConstU32<{ 128 * 1024 * 1024 }>;
type PVFMemory = ConstU32<{ 512 * 1024 * 1024 }>;
type UnsafeUnstableInterface = ConstBool<true>;
type UploadOrigin = EnsureRootWithSuccess<AccountId, TreasuryAccount>;
type InstantiateOrigin = EnsureRootWithSuccess<AccountId, TreasuryAccount>;
type RuntimeHoldReason = RuntimeHoldReason;
type CodeHashLockupDepositPercent = CodeHashLockupDepositPercent;
type ChainId = ChainId;
type NativeToEthRatio = ConstU32<1_000_000>; // 10^(18 - 12) Eth is 10^18, Native is 10^12.
type EthGasEncoder = ();
type FindAuthor = <Runtime as pallet_authorship::Config>::FindAuthor;
}
2 changes: 2 additions & 0 deletions runtime/kreivo/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,8 @@ mod runtime {
pub type Contracts = pallet_contracts;
#[runtime::pallet_index(81)]
pub type ContractsStore = pallet_contracts_store;
#[runtime::pallet_index(82)]
pub type Revive = pallet_revive;
}

cumulus_pallet_parachain_system::register_validate_block! {
Expand Down
Loading