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

Updates dkg-substrate to v0.3.5 #230

Merged
merged 6 commits into from
Jul 21, 2023
Merged
Show file tree
Hide file tree
Changes from 3 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
18 changes: 9 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,15 @@ paste = "1.0.6"


# DKG Substrate Dependencies
dkg-runtime-primitives = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2", default-features = false }
pallet-dkg-metadata = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2", default-features = false }
pallet-dkg-proposal-handler = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2", default-features = false }
pallet-dkg-proposals = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2", default-features = false }
pallet-bridge-registry = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2", default-features = false }
dkg-gadget = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2" }
dkg-primitives = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2" }
webb-relayer-gadget = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2" }
webb-relayer-gadget-cli = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.2" }
dkg-runtime-primitives = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5", default-features = false }
pallet-dkg-metadata = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5", default-features = false }
pallet-dkg-proposal-handler = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5", default-features = false }
pallet-dkg-proposals = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5", default-features = false }
pallet-bridge-registry = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5", default-features = false }
dkg-gadget = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5" }
dkg-primitives = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5" }
webb-relayer-gadget = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5" }
webb-relayer-gadget-cli = { git = "https://github.com/webb-tools/dkg-substrate.git", tag = "v0.3.5" }

tangle-runtime = { package = "tangle-standalone-runtime", path = "standalone/runtime" }

Expand Down
102 changes: 51 additions & 51 deletions types/src/interfaces/augment-api-consts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import type { ApiTypes, AugmentedConst } from '@polkadot/api-base/types';
import type { Bytes, Option, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
import type { Codec } from '@polkadot/types-codec/types';
import type { Perbill, Permill } from '@polkadot/types/interfaces/runtime';
import { SpWeightsWeightV2Weight, WebbProposalsHeaderTypedChainId, FrameSupportPalletId, FrameSystemLimitsBlockLength, FrameSystemLimitsBlockWeights, SpWeightsRuntimeDbWeight, SpVersionRuntimeVersion } from '@polkadot/types/lookup';
import { FrameSupportPalletId, FrameSystemLimitsBlockLength, FrameSystemLimitsBlockWeights, SpVersionRuntimeVersion, SpWeightsRuntimeDbWeight, SpWeightsWeightV2Weight, WebbProposalsHeaderTypedChainId } from '@polkadot/types/lookup';

export type __AugmentedConst<ApiType extends ApiTypes> = AugmentedConst<ApiType>;

Expand All @@ -18,35 +18,35 @@ declare module '@polkadot/api-base/types/consts' {
bagsList: {
/**
* The list of thresholds separating the various bags.
*
*
* Ids are separated into unsorted bags according to their score. This specifies the
* thresholds separating the bags. An id's bag is the largest bag for which the id's score
* is less than or equal to its upper threshold.
*
*
* When ids are iterated, higher bags are iterated completely before lower bags. This means
* that iteration is _semi-sorted_: ids of higher score tend to come before ids of lower
* score, but peer ids within a particular bag are sorted in insertion order.
*
*
* # Expressing the constant
*
*
* This constant must be sorted in strictly increasing order. Duplicate items are not
* permitted.
*
*
* There is an implied upper limit of `Score::MAX`; that value does not need to be
* specified within the bag. For any two threshold lists, if one ends with
* `Score::MAX`, the other one does not, and they are otherwise equal, the two
* lists will behave identically.
*
*
* # Calculation
*
*
* It is recommended to generate the set of thresholds in a geometric series, such that
* there exists some constant ratio such that `threshold[k + 1] == (threshold[k] *
* constant_ratio).max(threshold[k] + 1)` for all `k`.
*
*
* The helpers in the `/utils/frame/generate-bags` module can simplify this calculation.
*
*
* # Examples
*
*
* - If `BagThresholds::get().is_empty()`, then all ids are put into the same bag, and
* iteration is strictly in insertion order.
* - If `BagThresholds::get().len() == 64`, and the thresholds are determined according to
Expand All @@ -55,9 +55,9 @@ declare module '@polkadot/api-base/types/consts' {
* the procedure given above, then the constant ratio is approximately equal to 1.248.
* - If the threshold list begins `[1, 2, 3, ...]`, then an id with score 0 or 1 will fall
* into bag 0, an id with score 2 will fall into bag 1, etc.
*
*
* # Migration
*
*
* In the event that this list ever changes, a copy of the old bags list must be retained.
* With that `List::migrate` can be called, which will perform the appropriate migration.
**/
Expand All @@ -70,12 +70,12 @@ declare module '@polkadot/api-base/types/consts' {
balances: {
/**
* The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!
*
*
* If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for
* this pallet. However, you do so at your own risk: this will open up a major DoS vector.
* In case you have multiple sources of provider references, you may also get unexpected
* behaviour if you set this to zero.
*
*
* Bottom line: Do yourself a favour and make it at least one!
**/
existentialDeposit: u128 & AugmentedConst<ApiType>;
Expand Down Expand Up @@ -128,7 +128,7 @@ declare module '@polkadot/api-base/types/consts' {
curatorDepositMin: Option<u128> & AugmentedConst<ApiType>;
/**
* The curator deposit is calculated as a percentage of the curator fee.
*
*
* This deposit has optional upper and lower bounds with `CuratorDepositMax` and
* `CuratorDepositMin`.
**/
Expand All @@ -139,7 +139,7 @@ declare module '@polkadot/api-base/types/consts' {
dataDepositPerByte: u128 & AugmentedConst<ApiType>;
/**
* Maximum acceptable reason length.
*
*
* Benchmarks depend on this value, be sure to update weights file when changing this value
**/
maximumReasonLength: u32 & AugmentedConst<ApiType>;
Expand Down Expand Up @@ -207,7 +207,7 @@ declare module '@polkadot/api-base/types/consts' {
cooloffPeriod: u32 & AugmentedConst<ApiType>;
/**
* The period between a proposal being approved and enacted.
*
*
* It should generally be a little more than the unstake period to ensure that
* voting stakers have an opportunity to remove themselves from the system in the case
* where they are on the losing side of a vote.
Expand Down Expand Up @@ -241,7 +241,7 @@ declare module '@polkadot/api-base/types/consts' {
maxProposals: u32 & AugmentedConst<ApiType>;
/**
* The maximum number of votes for an account.
*
*
* Also used to compute weight, an overly big value can
* lead to extrinsic with very big weight: see `delegate` for instance.
**/
Expand All @@ -252,7 +252,7 @@ declare module '@polkadot/api-base/types/consts' {
minimumDeposit: u128 & AugmentedConst<ApiType>;
/**
* The minimum period of vote locking.
*
*
* It should be no shorter than enactment period to ensure that in the case of an approval,
* those successful voters are locked into the consequences that their votes entail.
**/
Expand Down Expand Up @@ -293,14 +293,14 @@ declare module '@polkadot/api-base/types/consts' {
sessionPeriod: u32 & AugmentedConst<ApiType>;
/**
* Number of blocks of cooldown after unsigned transaction is included.
*
*
* This ensures that we only accept unsigned transactions once, every `UnsignedInterval`
* blocks.
**/
unsignedInterval: u32 & AugmentedConst<ApiType>;
/**
* A configuration for base priority of unsigned transactions.
*
*
* This is exposed so that it can be tuned for particular runtime, when
* multiple pallets send unsigned transactions.
**/
Expand Down Expand Up @@ -389,7 +389,7 @@ declare module '@polkadot/api-base/types/consts' {
/**
* The maximum number of winners that can be elected by this `ElectionProvider`
* implementation.
*
*
* Note: This must always be greater or equal to `T::DataProvider::desired_targets()`.
**/
maxWinners: u32 & AugmentedConst<ApiType>;
Expand All @@ -403,7 +403,7 @@ declare module '@polkadot/api-base/types/consts' {
minerTxPriority: u64 & AugmentedConst<ApiType>;
/**
* The repeat threshold of the offchain worker.
*
*
* For example, if it is 5, that means that at least 5 blocks will elapse between attempts
* to submit the worker's solution.
**/
Expand All @@ -426,7 +426,7 @@ declare module '@polkadot/api-base/types/consts' {
signedMaxRefunds: u32 & AugmentedConst<ApiType>;
/**
* Maximum number of signed submissions that can be queued.
*
*
* It is best to avoid adjusting this during an election, as it impacts downstream data
* structures. In particular, `SignedSubmissionIndices<T>` is bounded on this value. If you
* update this value during an election, you _must_ ensure that
Expand All @@ -436,7 +436,7 @@ declare module '@polkadot/api-base/types/consts' {
signedMaxSubmissions: u32 & AugmentedConst<ApiType>;
/**
* Maximum weight of a signed solution.
*
*
* If [`Config::MinerConfig`] is being implemented to submit signed solutions (outside of
* this pallet), then [`MinerConfig::solution_weight`] is used to compare against
* this value.
Expand Down Expand Up @@ -474,25 +474,25 @@ declare module '@polkadot/api-base/types/consts' {
desiredRunnersUp: u32 & AugmentedConst<ApiType>;
/**
* The maximum number of candidates in a phragmen election.
*
*
* Warning: This impacts the size of the election which is run onchain. Chose wisely, and
* consider how it will impact `T::WeightInfo::election_phragmen`.
*
*
* When this limit is reached no more candidates are accepted in the election.
**/
maxCandidates: u32 & AugmentedConst<ApiType>;
/**
* The maximum number of voters to allow in a phragmen election.
*
*
* Warning: This impacts the size of the election which is run onchain. Chose wisely, and
* consider how it will impact `T::WeightInfo::election_phragmen`.
*
*
* When the limit is reached the new voters are ignored.
**/
maxVoters: u32 & AugmentedConst<ApiType>;
/**
* Maximum numbers of votes per voter.
*
*
* Warning: This impacts the size of the election which is run onchain. Chose wisely, and
* consider how it will impact `T::WeightInfo::election_phragmen`.
**/
Expand All @@ -509,7 +509,7 @@ declare module '@polkadot/api-base/types/consts' {
termDuration: u32 & AugmentedConst<ApiType>;
/**
* Base deposit associated with voting.
*
*
* This should be sensibly high to economically ensure the pallet cannot be attacked by
* creating a gigantic number of votes.
**/
Expand Down Expand Up @@ -537,7 +537,7 @@ declare module '@polkadot/api-base/types/consts' {
maxAuthorities: u32 & AugmentedConst<ApiType>;
/**
* The maximum number of entries to keep in the set id to session index mapping.
*
*
* Since the `SetIdSession` map is only used for validating equivocations this
* value should relate to the bonding duration of whatever staking system is
* being used (if any). If equivocation handling is not enabled then this value
Expand Down Expand Up @@ -586,7 +586,7 @@ declare module '@polkadot/api-base/types/consts' {
imOnline: {
/**
* A configuration for base priority of unsigned transactions.
*
*
* This is exposed so that it can be tuned for particular runtime, when
* multiple pallets send unsigned transactions.
**/
Expand All @@ -609,15 +609,15 @@ declare module '@polkadot/api-base/types/consts' {
nominationPools: {
/**
* The maximum pool points-to-balance ratio that an `open` pool can have.
*
*
* This is important in the event slashing takes place and the pool's points-to-balance
* ratio becomes disproportional.
*
*
* Moreover, this relates to the `RewardCounter` type as well, as the arithmetic operations
* are a function of number of points, and by setting this value to e.g. 10, you ensure
* that the total number of points in the system are at most 10 times the total_issuance of
* the chain, in the absolute worse case.
*
*
* For a value of 10, the threshold would be a pool points-to-balance ratio of 10:1.
* Such a scenario would also be the equivalent of the pool being 90% slashed.
**/
Expand All @@ -638,7 +638,7 @@ declare module '@polkadot/api-base/types/consts' {
maximumWeight: SpWeightsWeightV2Weight & AugmentedConst<ApiType>;
/**
* The maximum number of scheduled calls in the queue for a single block.
*
*
* NOTE:
* + Dependent pallets' benchmarks might require a higher limit for the setting. Set a
* higher limit under `runtime-benchmarks` feature.
Expand All @@ -656,20 +656,20 @@ declare module '@polkadot/api-base/types/consts' {
bondingDuration: u32 & AugmentedConst<ApiType>;
/**
* Number of eras to keep in history.
*
*
* Following information is kept for eras in `[current_era -
* HistoryDepth, current_era]`: `ErasStakers`, `ErasStakersClipped`,
* `ErasValidatorPrefs`, `ErasValidatorReward`, `ErasRewardPoints`,
* `ErasTotalStake`, `ErasStartSessionIndex`,
* `StakingLedger.claimed_rewards`.
*
*
* Must be more than the number of eras delayed by session.
* I.e. active era must always be in history. I.e. `active_era >
* current_era - history_depth` must be guaranteed.
*
*
* If migrating an existing pallet from storage value to config value,
* this should be set to same value or greater as in storage.
*
*
* Note: `HistoryDepth` is used as the upper bound for the `BoundedVec`
* item `StakingLedger.claimed_rewards`. Setting this value lower than
* the existing value can lead to inconsistencies in the
Expand All @@ -683,7 +683,7 @@ declare module '@polkadot/api-base/types/consts' {
maxNominations: u32 & AugmentedConst<ApiType>;
/**
* The maximum number of nominators rewarded for each validator.
*
*
* For each validator only the `$MaxNominatorRewardedPerValidator` biggest stakers can
* claim their reward. This used to limit the i/o cost for the nominator payout.
**/
Expand All @@ -692,7 +692,7 @@ declare module '@polkadot/api-base/types/consts' {
* The maximum number of `unlocking` chunks a [`StakingLedger`] can
* have. Effectively determines how many unique eras a staker may be
* unbonding in.
*
*
* Note: `MaxUnlockingChunks` is used as the upper bound for the
* `BoundedVec` item `StakingLedger.unlocking`. Setting this value
* lower than the existing value can lead to inconsistencies in the
Expand All @@ -707,7 +707,7 @@ declare module '@polkadot/api-base/types/consts' {
sessionsPerEra: u32 & AugmentedConst<ApiType>;
/**
* Number of eras that slashes are deferred by, after computation.
*
*
* This should be less than the bonding duration. Set to 0 if slashes
* should be applied immediately, without opportunity for intervention.
**/
Expand Down Expand Up @@ -736,7 +736,7 @@ declare module '@polkadot/api-base/types/consts' {
dbWeight: SpWeightsRuntimeDbWeight & AugmentedConst<ApiType>;
/**
* The designated SS58 prefix of this chain.
*
*
* This replaces the "ss58Format" property declared in the chain spec. Reason is
* that the runtime should know about the prefix in order to make use of it as
* an identifier of the chain.
Expand Down Expand Up @@ -768,21 +768,21 @@ declare module '@polkadot/api-base/types/consts' {
/**
* A fee mulitplier for `Operational` extrinsics to compute "virtual tip" to boost their
* `priority`
*
*
* This value is multipled by the `final_fee` to obtain a "virtual tip" that is later
* added to a tip component in regular `priority` calculations.
* It means that a `Normal` transaction can front-run a similarly-sized `Operational`
* extrinsic (with no tip), by including a tip value greater than the virtual tip.
*
*
* ```rust,ignore
* // For `Normal`
* let priority = priority_calc(tip);
*
*
* // For `Operational`
* let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;
* let priority = priority_calc(tip + virtual_tip);
* ```
*
*
* Note that since we use `final_fee` the multiplier applies also to the regular `tip`
* sent with the transaction. So, not only does the transaction get a priority bump based
* on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`
Expand All @@ -801,7 +801,7 @@ declare module '@polkadot/api-base/types/consts' {
burn: Permill & AugmentedConst<ApiType>;
/**
* The maximum number of approvals that can wait in the spending queue.
*
*
* NOTE: This parameter is also used within the Bounties Pallet extension if enabled.
**/
maxApprovals: u32 & AugmentedConst<ApiType>;
Expand Down
Loading
Loading