Skip to content

Commit 22bc168

Browse files
authored
0.28.2 release (#450)
- align staking params & fix MAXIMUM_BLOCK_WEIGHT - align chainspecs
1 parent 4efca8e commit 22bc168

File tree

7 files changed

+56
-55
lines changed

7 files changed

+56
-55
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
id: set_vars
1717
run: |
1818
RELEASE_NAME=${{ github.event.release.name }}
19-
echo "RELEASE_VERSION=${RELEASE_NAME#v}" >> $GITHUB_OUTPUT
19+
echo "RELEASE_VERSION=${RELEASE_NAME}" >> $GITHUB_OUTPUT
2020
2121
publish:
2222
needs: [init]

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ orml-asset-registry = { git = "https://github.com/mangata-finance//open-runtime-
4545

4646
# patch generated by ./scripts/dev_manifest.sh
4747
[patch."https://github.com/mangata-finance/moonbeam"]
48-
parachain-staking = { git = "https://github.com/mangata-finance//moonbeam", branch = "mangata-dev" }
48+
# parachain-staking = { path = "../moonbeam/pallets/parachain-staking" }
49+
parachain-staking = { git = "https://github.com/mangata-finance//moonbeam", tag = "v0.28.2" }
4950

5051
[patch."https://github.com/mangata-finance/crowdloan-rewards"]
5152
pallet-crowdloan-rewards = { git = "https://github.com/mangata-finance//crowdloan-rewards", branch = "mangata-dev" }

node/src/chain_spec/mangata_kusama.rs

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -162,31 +162,31 @@ pub fn kusama_mainnet_config() -> ChainSpec {
162162
// Id of MGA token,
163163
0u32,
164164
// How much mangata they pool
165-
10_000__000_000_000_000_000_000u128,
165+
10_000_000__000_000_000_000_000_000u128,
166166
// Id of the dummy token,
167167
2u32,
168168
// How many dummy tokens they pool,
169-
20_000__000_000_000_000_000_000u128,
169+
20_000_000__000_000_000_000_000_000u128,
170170
// Id of the liquidity token that is generated
171171
3u32,
172172
// How many liquidity tokens they stake,
173-
10_000__000_000_000_000_000_000u128,
173+
10_000_000__000_000_000_000_000_000u128,
174174
),
175175
(
176176
// Who gets to stake initially
177177
kusama_mainnet_keys::BOB_SR25519.parse::<AccountId>().unwrap().into(),
178178
// Id of MGA token,
179179
0u32,
180180
// How much mangata they pool
181-
8_000__000_000_000_000_000_000u128,
181+
8_000_000__000_000_000_000_000_000u128,
182182
// Id of the dummy token,
183183
2u32,
184184
// How many dummy tokens they pool,
185-
20_000__000_000_000_000_000_000u128,
185+
20_000_000__000_000_000_000_000_000u128,
186186
// Id of the liquidity token that is generated
187187
3u32,
188188
// How many liquidity tokens they stake,
189-
5_000__000_000_000_000_000_000u128,
189+
5_000_000__000_000_000_000_000_000u128,
190190
),
191191
],
192192
vec![
@@ -318,31 +318,31 @@ pub fn development_config() -> ChainSpec {
318318
// Id of MGA token,
319319
0u32,
320320
// How much mangata they pool
321-
10_000__000_000_000_000_000_000u128,
321+
10_000_000__000_000_000_000_000_000u128,
322322
// Id of the dummy token,
323323
2u32,
324324
// How many dummy tokens they pool,
325-
20_000__000_000_000_000_000_000u128,
325+
20_000_000__000_000_000_000_000_000u128,
326326
// Id of the liquidity token that is generated
327327
3u32,
328328
// How many liquidity tokens they stake,
329-
10_000__000_000_000_000_000_000u128,
329+
10_000_000__000_000_000_000_000_000u128,
330330
),
331331
(
332332
// Who gets to stake initially
333333
get_account_id_from_seed::<sr25519::Public>("Bob"),
334334
// Id of MGA token,
335335
0u32,
336336
// How much mangata they pool
337-
8_000__000_000_000_000_000_000u128,
337+
8_000_000__000_000_000_000_000_000u128,
338338
// Id of the dummy token,
339339
2u32,
340340
// How many dummy tokens they pool,
341-
20_000__000_000_000_000_000_000u128,
341+
20_000_000__000_000_000_000_000_000u128,
342342
// Id of the liquidity token that is generated
343343
3u32,
344344
// How many liquidity tokens they stake,
345-
5_000__000_000_000_000_000_000u128,
345+
5_000_000__000_000_000_000_000_000u128,
346346
),
347347
],
348348
vec![
@@ -476,31 +476,31 @@ pub fn local_config() -> ChainSpec {
476476
// Id of MGA token,
477477
0u32,
478478
// How much mangata they pool
479-
10_000__000_000_000_000_000_000u128,
479+
10_000_000__000_000_000_000_000_000u128,
480480
// Id of the dummy token,
481481
2u32,
482482
// How many dummy tokens they pool,
483-
20_000__000_000_000_000_000_000u128,
483+
20_000_000__000_000_000_000_000_000u128,
484484
// Id of the liquidity token that is generated
485485
3u32,
486486
// How many liquidity tokens they stake,
487-
10_000__000_000_000_000_000_000u128,
487+
10_000_000__000_000_000_000_000_000u128,
488488
),
489489
(
490490
// Who gets to stake initially
491491
get_account_id_from_seed::<sr25519::Public>("Bob"),
492492
// Id of MGA token,
493493
0u32,
494494
// How much mangata they pool
495-
8_000__000_000_000_000_000_000u128,
495+
8_000_000__000_000_000_000_000_000u128,
496496
// Id of the dummy token,
497497
2u32,
498498
// How many dummy tokens they pool,
499-
20_000__000_000_000_000_000_000u128,
499+
20_000_000__000_000_000_000_000_000u128,
500500
// Id of the liquidity token that is generated
501501
3u32,
502502
// How many liquidity tokens they stake,
503-
5_000__000_000_000_000_000_000u128,
503+
5_000_000__000_000_000_000_000_000u128,
504504
),
505505
],
506506
vec![

node/src/chain_spec/mangata_rococo.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -148,31 +148,31 @@ pub fn public_testnet_config() -> ChainSpec {
148148
// Id of MGA token,
149149
0u32,
150150
// How much mangata they pool
151-
10_000__000_000_000_000_000_000u128,
151+
10_000_000__000_000_000_000_000_000u128,
152152
// Id of the dummy token,
153153
2u32,
154154
// How many dummy tokens they pool,
155-
20_000__000_000_000_000_000_000u128,
155+
20_000_000__000_000_000_000_000_000u128,
156156
// Id of the liquidity token that is generated
157157
3u32,
158158
// How many liquidity tokens they stake,
159-
10_000__000_000_000_000_000_000u128,
159+
10_000_000__000_000_000_000_000_000u128,
160160
),
161161
(
162162
// Who gets to stake initially
163163
public_testnet_keys::BOB_SR25519.parse::<AccountId>().unwrap().into(),
164164
// Id of MGA token,
165165
0u32,
166166
// How much mangata they pool
167-
8_000__000_000_000_000_000_000u128,
167+
8_000_000__000_000_000_000_000_000u128,
168168
// Id of the dummy token,
169169
2u32,
170170
// How many dummy tokens they pool,
171-
20_000__000_000_000_000_000_000u128,
171+
20_000_000__000_000_000_000_000_000u128,
172172
// Id of the liquidity token that is generated
173173
3u32,
174174
// How many liquidity tokens they stake,
175-
5_000__000_000_000_000_000_000u128,
175+
5_000_000__000_000_000_000_000_000u128,
176176
),
177177
],
178178
vec![
@@ -297,31 +297,31 @@ pub fn mangata_rococo_local_config() -> ChainSpec {
297297
// Id of MGA token,
298298
0u32,
299299
// How much mangata they pool
300-
10_000__000_000_000_000_000_000u128,
300+
10_000_000__000_000_000_000_000_000u128,
301301
// Id of the dummy token,
302302
2u32,
303303
// How many dummy tokens they pool,
304-
20_000__000_000_000_000_000_000u128,
304+
20_000_000__000_000_000_000_000_000u128,
305305
// Id of the liquidity token that is generated
306306
3u32,
307307
// How many liquidity tokens they stake,
308-
10_000__000_000_000_000_000_000u128,
308+
10_000_000__000_000_000_000_000_000u128,
309309
),
310310
(
311311
// Who gets to stake initially
312312
get_account_id_from_seed::<sr25519::Public>("Bob"),
313313
// Id of MGA token,
314314
0u32,
315315
// How much mangata they pool
316-
8_000__000_000_000_000_000_000u128,
316+
8_000_000__000_000_000_000_000_000u128,
317317
// Id of the dummy token,
318318
2u32,
319319
// How many dummy tokens they pool,
320-
20_000__000_000_000_000_000_000u128,
320+
20_000_000__000_000_000_000_000_000u128,
321321
// Id of the liquidity token that is generated
322322
3u32,
323323
// How many liquidity tokens they stake,
324-
5_000__000_000_000_000_000_000u128,
324+
5_000_000__000_000_000_000_000_000u128,
325325
),
326326
],
327327
vec![

runtime/mangata-kusama/src/lib.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,11 @@ impl_opaque_keys! {
160160
pub const VERSION: RuntimeVersion = RuntimeVersion {
161161
spec_name: create_runtime_str!("mangata-parachain"),
162162
impl_name: create_runtime_str!("mangata-parachain"),
163-
authoring_version: 14,
164-
spec_version: 14,
163+
authoring_version: 15,
164+
spec_version: 15,
165165
impl_version: 0,
166166
apis: RUNTIME_API_VERSIONS,
167-
transaction_version: 14,
167+
transaction_version: 15,
168168
state_version: 0,
169169
};
170170

@@ -174,10 +174,10 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
174174
spec_name: create_runtime_str!("mangata-parachain"),
175175
impl_name: create_runtime_str!("mangata-parachain"),
176176
authoring_version: 15,
177-
spec_version: 15,
177+
spec_version: 002802,
178178
impl_version: 0,
179179
apis: RUNTIME_API_VERSIONS,
180-
transaction_version: 15,
180+
transaction_version: 002802,
181181
state_version: 0,
182182
};
183183

@@ -229,10 +229,10 @@ const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75);
229229
/// We allow for 0.5 of a second of compute with a 12 second average block time.
230230
/// NOTE: reduced by half comparing to origin impl as we want to fill block only up to 50%
231231
/// so there is room for new extrinsics in the next block
232-
// const MAXIMUM_BLOCK_WEIGHT: Weight =
233-
// WEIGHT_PER_SECOND.saturating_div(4).set_proof_size((cumulus_primitives_core::relay_chain::v2::MAX_POV_SIZE as u64).saturating_div(2));
234-
const MAXIMUM_BLOCK_WEIGHT: Weight =
235-
Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), u64::MAX);
232+
const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts(
233+
WEIGHT_REF_TIME_PER_SECOND.saturating_div(4),
234+
cumulus_primitives_core::relay_chain::v2::MAX_POV_SIZE as u64,
235+
);
236236

237237
/// The version information used to identify this runtime when compiled natively.
238238
#[cfg(feature = "std")]
@@ -1293,7 +1293,7 @@ parameter_types! {
12931293
/// Minimum collators selected per round, default at genesis and minimum forever after
12941294
pub const MinSelectedCandidates: u32 = 25;
12951295
/// Maximum collator candidates allowed
1296-
pub const MaxCollatorCandidates: u32 = 35;
1296+
pub const MaxCollatorCandidates: u32 = 50;
12971297
/// Maximum delegators allowed per candidate
12981298
pub const MaxTotalDelegatorsPerCandidate: u32 = 25;
12991299
/// Maximum delegators counted per candidate
@@ -1305,7 +1305,7 @@ parameter_types! {
13051305
/// Minimum stake required to become a collator
13061306
pub const MinCollatorStk: u128 = 10 * DOLLARS;
13071307
/// Minimum stake required to be reserved to be a candidate
1308-
pub const MinCandidateStk: u128 = 1 * DOLLARS;
1308+
pub const MinCandidateStk: u128 = 1_500_000 * DOLLARS;
13091309
/// Minimum stake required to be reserved to be a delegator
13101310
pub const MinDelegatorStk: u128 = 1 * CENTS;
13111311
}

runtime/mangata-rococo/src/lib.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,11 @@ impl_opaque_keys! {
160160
pub const VERSION: RuntimeVersion = RuntimeVersion {
161161
spec_name: create_runtime_str!("mangata-parachain"),
162162
impl_name: create_runtime_str!("mangata-parachain"),
163-
authoring_version: 13,
164-
spec_version: 13,
163+
authoring_version: 14,
164+
spec_version: 14,
165165
impl_version: 0,
166166
apis: RUNTIME_API_VERSIONS,
167-
transaction_version: 13,
167+
transaction_version: 14,
168168
state_version: 0,
169169
};
170170

@@ -174,10 +174,10 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
174174
spec_name: create_runtime_str!("mangata-parachain"),
175175
impl_name: create_runtime_str!("mangata-parachain"),
176176
authoring_version: 14,
177-
spec_version: 14,
177+
spec_version: 002802,
178178
impl_version: 0,
179179
apis: RUNTIME_API_VERSIONS,
180-
transaction_version: 14,
180+
transaction_version: 002802,
181181
state_version: 0,
182182
};
183183

@@ -229,10 +229,10 @@ const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75);
229229
/// We allow for 0.5 of a second of compute with a 12 second average block time.
230230
/// NOTE: reduced by half comparing to origin impl as we want to fill block only up to 50%
231231
/// so there is room for new extrinsics in the next block
232-
// const MAXIMUM_BLOCK_WEIGHT: Weight =
233-
// WEIGHT_PER_SECOND.saturating_div(4).set_proof_size((cumulus_primitives_core::relay_chain::v2::MAX_POV_SIZE as u64).saturating_div(2));
234-
const MAXIMUM_BLOCK_WEIGHT: Weight =
235-
Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), u64::MAX);
232+
const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts(
233+
WEIGHT_REF_TIME_PER_SECOND.saturating_div(4),
234+
cumulus_primitives_core::relay_chain::v2::MAX_POV_SIZE as u64,
235+
);
236236

237237
/// The version information used to identify this runtime when compiled natively.
238238
#[cfg(feature = "std")]
@@ -1284,7 +1284,7 @@ parameter_types! {
12841284
/// Minimum collators selected per round, default at genesis and minimum forever after
12851285
pub const MinSelectedCandidates: u32 = 25;
12861286
/// Maximum collator candidates allowed
1287-
pub const MaxCollatorCandidates: u32 = 35;
1287+
pub const MaxCollatorCandidates: u32 = 50;
12881288
/// Maximum delegators allowed per candidate
12891289
pub const MaxTotalDelegatorsPerCandidate: u32 = 25;
12901290
/// Maximum delegators counted per candidate
@@ -1296,7 +1296,7 @@ parameter_types! {
12961296
/// Minimum stake required to become a collator
12971297
pub const MinCollatorStk: u128 = 10 * DOLLARS;
12981298
/// Minimum stake required to be reserved to be a candidate
1299-
pub const MinCandidateStk: u128 = 1 * DOLLARS;
1299+
pub const MinCandidateStk: u128 = 1_500_000 * DOLLARS;
13001300
/// Minimum stake required to be reserved to be a delegator
13011301
pub const MinDelegatorStk: u128 = 1 * CENTS;
13021302
}

0 commit comments

Comments
 (0)