Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0caae6beb5 | ||
|
|
7f92bb33bc | ||
|
|
20b39c18f6 | ||
|
|
f6907eb5de | ||
|
|
8880785951 | ||
|
|
c4a4e1acd7 | ||
|
|
e1cf75288c | ||
|
|
be95356999 | ||
|
|
b66d62548a | ||
|
|
bee7db805a | ||
|
|
ca7a382c5b | ||
|
|
40393ddc1e | ||
|
|
5bd2a664ec | ||
|
|
52ef27806b | ||
|
|
8e234f8a98 | ||
|
|
5e9ba771b5 | ||
|
|
e855dca167 | ||
|
|
3da1bbe403 | ||
|
|
5740c00259 | ||
|
|
8bb8fa0f32 | ||
|
|
30bd10c3b3 | ||
|
|
f7b647f4c6 | ||
|
|
3ae8e32c84 | ||
|
|
3dbba5e5ba | ||
|
|
7e3b8bf5fc | ||
|
|
14b8d25fb1 | ||
|
|
d64a1fcfd3 | ||
|
|
41bf6fa8ea | ||
|
|
faa28f2822 | ||
|
|
528a2b041b | ||
|
|
7a0f103545 | ||
|
|
0565492ae8 | ||
|
|
af7820a0a2 | ||
|
|
69e754105d | ||
|
|
8fc143ceab | ||
|
|
af072be808 | ||
|
|
8d86def88b | ||
|
|
a99f848adb | ||
|
|
f53db7dbf0 | ||
|
|
26d1d0d695 | ||
|
|
ed33850c62 | ||
|
|
6983f8c883 | ||
|
|
71ddc66515 | ||
|
|
e3ba160935 | ||
|
|
b824edd281 | ||
|
|
b397486fe8 | ||
|
|
28d1d8193b | ||
|
|
6cb0c5c5be | ||
|
|
f4072b9202 | ||
|
|
8d300a73b8 | ||
|
|
d6d24d5b61 | ||
|
|
0ef93c3b94 | ||
|
|
a6b48f8eec | ||
|
|
a92bfca548 | ||
|
|
7701205d58 | ||
|
|
2d09e8d94e | ||
|
|
7b0fd81b4e | ||
|
|
c1a6f3f302 | ||
|
|
62df7e4ead | ||
|
|
f2cb628e25 | ||
|
|
5b0eb1b67b | ||
|
|
87affdcbb3 | ||
|
|
4afd550db7 | ||
|
|
cebcc054da | ||
|
|
dc9c225eb8 | ||
|
|
a3b0d9a794 | ||
|
|
43efff7ade | ||
|
|
a81d83a25c | ||
|
|
6dea8d9a07 | ||
|
|
4677ecc55f | ||
|
|
4038260b37 | ||
|
|
ec87b5b244 | ||
|
|
421f767b0d | ||
|
|
cfc7e2490c | ||
|
|
2051a3d772 |
@@ -1,5 +1,68 @@
|
|||||||
# CHANGELOG
|
# CHANGELOG
|
||||||
|
|
||||||
|
## 9.6.1 Oct 23, 2022
|
||||||
|
|
||||||
|
Contributed:
|
||||||
|
|
||||||
|
- Update `@substrate/connect` to latest (Thanks to https://github.com/wirednkod)
|
||||||
|
- Use `.?` operators in submittable class (Thanks to https://github.com/shunjizhan)
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
|
||||||
|
- Cater for latest Substrate `DispatchError` (additional preimage statuses)
|
||||||
|
- Adjust `api.derive.democracy.*` to return `imageHash` as `HexString` (as applicable, supports current-gen preimages)
|
||||||
|
- Adjust `api.derive.preimages.*` to retrieve via `democracy` or `preimage` pallets
|
||||||
|
- Ensure `apiAt.<section>.<method>.key(...)` passes through the correct arguments
|
||||||
|
- Apply fallback for Weight downgrades (V2 >> V1 detection)
|
||||||
|
- Update to latest Substrate metadata
|
||||||
|
- Polkadot 9291 & Westend 9300 upgrade blocks
|
||||||
|
|
||||||
|
|
||||||
|
## 9.5.2 Oct 16, 2022
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
|
||||||
|
- Add `ParachainHost` version 3 runtime calls
|
||||||
|
|
||||||
|
|
||||||
|
## 9.5.1 Oct 8, 2022
|
||||||
|
|
||||||
|
- **Important** While the API witll detect and decorate the weight type based on V1 or V2, the default `Weight` type (used in runtime calls and RPCs) has not been swapped from the old `u64` variant. This means that on new chains using `WeightV2`, the TS decorated type will still reflect the old version.
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
|
||||||
|
- Adjust handling of `Weight` type for V2 structures
|
||||||
|
- Add alis definitions for `Weight{V1, V2}` (used for type overrides)
|
||||||
|
- Cater for weight v2 (along with v1 pass-through) extrinsics in `api-contract`
|
||||||
|
- Update to latest Substrate, Polkadot & Kusama metadata
|
||||||
|
|
||||||
|
|
||||||
|
## 9.4.3 Oct 2, 2022
|
||||||
|
|
||||||
|
Contributed:
|
||||||
|
|
||||||
|
- Allow for new `ink_primitives` types (Thanks to https://github.com/statictype)
|
||||||
|
- Fix contracts runtime `instantiate` call params (Thanks to https://github.com/statictype)
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
|
||||||
|
- Align staking derive redeemableSum with Rust source (`currentEra` vs `activeEra` usage)
|
||||||
|
- Add `@deprecated` flag to RPC interface generation (`contracts_*` & `state_get{Pairs/Keys}`)
|
||||||
|
- Polkadot 9280/9281, Kusama 9291 upgrade blocks
|
||||||
|
|
||||||
|
|
||||||
|
## 9.4.2 Sep 24, 2022
|
||||||
|
|
||||||
|
Contributed:
|
||||||
|
|
||||||
|
- Allow for re-subscriptions on `ScProvider` (Thanks to https://github.com/wirednkod)
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
|
||||||
|
- Align derives to cater for latest (& previous) Substrate interfaces
|
||||||
|
- Update to latest Substrate, Polkadot & Kusama metadata
|
||||||
|
|
||||||
|
|
||||||
## 9.4.1 Sep 17, 2022
|
## 9.4.1 Sep 17, 2022
|
||||||
|
|
||||||
Contributed:
|
Contributed:
|
||||||
|
|||||||
+4
-3
@@ -1,13 +1,13 @@
|
|||||||
3229 Jaco 9.4.1 (#5225)
|
3261 Jaco 9.6.1 (#5289)
|
||||||
83 Amaury Martiny StatementKind: Regular and Saft (#2303)
|
83 Amaury Martiny StatementKind: Regular and Saft (#2303)
|
||||||
37 Keith Ingram Update contract types and rpc (#4541)
|
37 Keith Ingram Update contract types and rpc (#4541)
|
||||||
35 Stefanie Doll Updated child storage parameters (#1709)
|
35 Stefanie Doll Updated child storage parameters (#1709)
|
||||||
20 Luke Schoen fix: Fixes TypeError: Cannot read property 'vesting' of undefined (#1970)
|
20 Luke Schoen fix: Fixes TypeError: Cannot read property 'vesting' of undefined (#1970)
|
||||||
16 Xiliang Chen implement entriesPaged and keysPages for query at (#4701)
|
16 Xiliang Chen implement entriesPaged and keysPages for query at (#4701)
|
||||||
15 Jeremías Díaz feat(types): add correct tuple type to storage key (#3054)
|
15 Jeremías Díaz feat(types): add correct tuple type to storage key (#3054)
|
||||||
|
13 Nikos Kontakis Bump Substrate connect to 0.7.15 (#5275)
|
||||||
11 Ian He HttpProvider support clone() (#3949)
|
11 Ian He HttpProvider support clone() (#3949)
|
||||||
10 Axel Chalon Make Enum/Tuple constructor use value directly if instance (#1954)
|
10 Axel Chalon Make Enum/Tuple constructor use value directly if instance (#1954)
|
||||||
10 Nikos Kontakis Bump substrate connect to 0.7.12 (#5214)
|
|
||||||
5 Chevdor Fix metadata package link (#3458)
|
5 Chevdor Fix metadata package link (#3458)
|
||||||
5 Jake Naviasky Fixing approvalFlagsToBools. (#1250)
|
5 Jake Naviasky Fixing approvalFlagsToBools. (#1250)
|
||||||
4 Alex D Use derive customAccount and customLocks for balance overrides (#3248)
|
4 Alex D Use derive customAccount and customLocks for balance overrides (#3248)
|
||||||
@@ -18,6 +18,7 @@
|
|||||||
4 Scott Twiname Add support for historical BlockNumber rpc methods (#4574)
|
4 Scott Twiname Add support for historical BlockNumber rpc methods (#4574)
|
||||||
4 Thibaut Sardan no subscription for http (#3127)
|
4 Thibaut Sardan no subscription for http (#3127)
|
||||||
3 André Silva add support for ValidationCodeHash (#3640)
|
3 André Silva add support for ValidationCodeHash (#3640)
|
||||||
|
3 Andreea Eftene Fix code source type (#5236)
|
||||||
3 Antoine Estienne Adapted to display moonbeam author (#3108)
|
3 Antoine Estienne Adapted to display moonbeam author (#3108)
|
||||||
3 Arjan Zijderveld Added `Emergency` to `ElectionPhase` (#3707)
|
3 Arjan Zijderveld Added `Emergency` to `ElectionPhase` (#3707)
|
||||||
3 Ewa Kowalska Handle no council for bounties proposals (#3062)
|
3 Ewa Kowalska Handle no council for bounties proposals (#3062)
|
||||||
@@ -45,7 +46,6 @@
|
|||||||
2 Zannis Kalampoukis fix: Typegen handles structs and vectors of structs without erroring (#4743)
|
2 Zannis Kalampoukis fix: Typegen handles structs and vectors of structs without erroring (#4743)
|
||||||
2 扩散性百万甜面包 Typo, deocrateMethod -> decorateMethod (#1594)
|
2 扩散性百万甜面包 Typo, deocrateMethod -> decorateMethod (#1594)
|
||||||
1 Alan Sapede Adds Eth feeHistory & maxPriorityFeePerGas rpc (#4956)
|
1 Alan Sapede Adds Eth feeHistory & maxPriorityFeePerGas rpc (#4956)
|
||||||
1 Andreea Eftene Add storage deposit support (#4304)
|
|
||||||
1 Brad Larson [NEW] Support for custom headers with providers (#2423)
|
1 Brad Larson [NEW] Support for custom headers with providers (#2423)
|
||||||
1 Btwiuse Arch Add side effect check workaround (#4994) (#5009)
|
1 Btwiuse Arch Add side effect check workaround (#4994) (#5009)
|
||||||
1 chriswmercer little readme tweak (#279)
|
1 chriswmercer little readme tweak (#279)
|
||||||
@@ -101,6 +101,7 @@
|
|||||||
1 Sean Young Solang requires u256 and i256 types (#2752)
|
1 Sean Young Solang requires u256 and i256 types (#2752)
|
||||||
1 serge make WS provider timeout configurable (#4758)
|
1 serge make WS provider timeout configurable (#4758)
|
||||||
1 Sergei Pepyakin INK! -> ink! (#1347)
|
1 Sergei Pepyakin INK! -> ink! (#1347)
|
||||||
|
1 Shunji Zhan small polish (#5276)
|
||||||
1 WoeOm adapt Darwinia, Crab Network types (#3498)
|
1 WoeOm adapt Darwinia, Crab Network types (#3498)
|
||||||
1 Xat_MassacrE Fix packages/types/src/codec/utils/encodeTypes.ts encodeSubTypes bug (#1544)
|
1 Xat_MassacrE Fix packages/types/src/codec/utils/encodeTypes.ts encodeSubTypes bug (#1544)
|
||||||
1 yjh fix MetadataVersioned.asV12 (#2983)
|
1 yjh fix MetadataVersioned.asV12 (#2983)
|
||||||
|
|||||||
+8
-8
@@ -11,10 +11,10 @@
|
|||||||
},
|
},
|
||||||
"sideEffects": false,
|
"sideEffects": false,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"versions": {
|
"versions": {
|
||||||
"git": "9.4.1",
|
"git": "9.6.1",
|
||||||
"npm": "9.4.1"
|
"npm": "9.6.1"
|
||||||
},
|
},
|
||||||
"workspaces": [
|
"workspaces": [
|
||||||
"packages/*"
|
"packages/*"
|
||||||
@@ -36,15 +36,15 @@
|
|||||||
"test:one": "NODE_OPTIONS=--experimental-vm-modules polkadot-dev-run-test --detectOpenHandles --forceExit"
|
"test:one": "NODE_OPTIONS=--experimental-vm-modules polkadot-dev-run-test --detectOpenHandles --forceExit"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "^7.19.1",
|
"@babel/core": "^7.19.6",
|
||||||
"@babel/register": "^7.18.9",
|
"@babel/register": "^7.18.9",
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/dev": "^0.67.130",
|
"@polkadot/dev": "^0.67.147",
|
||||||
"@polkadot/typegen": "workspace:packages/typegen",
|
"@polkadot/typegen": "workspace:packages/typegen",
|
||||||
"@types/jest": "^29.0.3",
|
"@types/jest": "^29.2.0",
|
||||||
"copyfiles": "^2.4.1"
|
"copyfiles": "^2.4.1"
|
||||||
},
|
},
|
||||||
"resolutions": {
|
"resolutions": {
|
||||||
"typescript": "^4.8.3"
|
"typescript": "^4.8.4"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,18 +20,18 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/api-base": "9.4.1",
|
"@polkadot/api-base": "9.6.1",
|
||||||
"@polkadot/rpc-augment": "9.4.1",
|
"@polkadot/rpc-augment": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-augment": "9.4.1",
|
"@polkadot/types-augment": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/types-support": "9.4.1"
|
"@polkadot/types-support": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -727,6 +727,29 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* Number of eras that staked funds must remain bonded for.
|
* Number of eras that staked funds must remain bonded for.
|
||||||
**/
|
**/
|
||||||
bondingDuration: u32 & AugmentedConst<ApiType>;
|
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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a migration.
|
||||||
|
* The test `reducing_history_depth_abrupt` shows this effect.
|
||||||
|
**/
|
||||||
|
historyDepth: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Maximum number of nominations per nominator.
|
* Maximum number of nominations per nominator.
|
||||||
**/
|
**/
|
||||||
@@ -739,8 +762,16 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
**/
|
**/
|
||||||
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The maximum number of `unlocking` chunks a [`StakingLedger`] can have. Effectively
|
* The maximum number of `unlocking` chunks a [`StakingLedger`] can
|
||||||
* determines how many unique eras a staker may be unbonding in.
|
* 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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a runtime
|
||||||
|
* migration. The test `reducing_max_unlocking_chunks_abrupt` shows
|
||||||
|
* this effect.
|
||||||
**/
|
**/
|
||||||
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -570,6 +570,38 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedError<ApiType>;
|
[key: string]: AugmentedError<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* The provided un-staker is already in Head, and cannot deregister.
|
||||||
|
**/
|
||||||
|
AlreadyHead: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has already been queued.
|
||||||
|
**/
|
||||||
|
AlreadyQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The call is not allowed at this point because the pallet is not active.
|
||||||
|
**/
|
||||||
|
CallNotAllowed: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided Controller account was not found.
|
||||||
|
*
|
||||||
|
* This means that the given account is not bonded.
|
||||||
|
**/
|
||||||
|
NotController: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has active unlocking chunks.
|
||||||
|
**/
|
||||||
|
NotFullyBonded: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided un-staker is not in the `Queue`.
|
||||||
|
**/
|
||||||
|
NotQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Generic error
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedError<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* The amount of the bid is less than the minimum allowed.
|
* The amount of the bid is less than the minimum allowed.
|
||||||
@@ -1682,6 +1714,10 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* A nomination target was supplied that was blocked or otherwise not a validator.
|
* A nomination target was supplied that was blocked or otherwise not a validator.
|
||||||
**/
|
**/
|
||||||
BadTarget: AugmentedError<ApiType>;
|
BadTarget: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Some bound is not met.
|
||||||
|
**/
|
||||||
|
BoundNotMet: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
||||||
**/
|
**/
|
||||||
|
|||||||
@@ -377,6 +377,33 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* A staker was partially checked for the given eras, but the process did not finish.
|
||||||
|
**/
|
||||||
|
Checking: AugmentedEvent<ApiType, [stash: AccountId32, eras: Vec<u32>], { stash: AccountId32, eras: Vec<u32> }>;
|
||||||
|
/**
|
||||||
|
* Some internal error happened while migrating stash. They are removed as head as a
|
||||||
|
* consequence.
|
||||||
|
**/
|
||||||
|
Errored: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
|
/**
|
||||||
|
* An internal error happened. Operations will be paused now.
|
||||||
|
**/
|
||||||
|
InternalError: AugmentedEvent<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* A staker was slashed for requesting fast-unstake whilst being exposed.
|
||||||
|
**/
|
||||||
|
Slashed: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
|
/**
|
||||||
|
* A staker was unstaked.
|
||||||
|
**/
|
||||||
|
Unstaked: AugmentedEvent<ApiType, [stash: AccountId32, result: Result<Null, SpRuntimeDispatchError>], { stash: AccountId32, result: Result<Null, SpRuntimeDispatchError> }>;
|
||||||
|
/**
|
||||||
|
* Generic event
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* A bid was successfully placed.
|
* A bid was successfully placed.
|
||||||
@@ -778,11 +805,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* An announcement was placed to make a call in the future.
|
* An announcement was placed to make a call in the future.
|
||||||
**/
|
**/
|
||||||
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
||||||
/**
|
|
||||||
* Anonymous account has been created by new proxy with given
|
|
||||||
* disambiguation index and proxy type.
|
|
||||||
**/
|
|
||||||
AnonymousCreated: AugmentedEvent<ApiType, [anonymous: AccountId32, who: AccountId32, proxyType: KusamaRuntimeProxyType, disambiguationIndex: u16], { anonymous: AccountId32, who: AccountId32, proxyType: KusamaRuntimeProxyType, disambiguationIndex: u16 }>;
|
|
||||||
/**
|
/**
|
||||||
* A proxy was added.
|
* A proxy was added.
|
||||||
**/
|
**/
|
||||||
@@ -795,6 +817,11 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* A proxy was removed.
|
* A proxy was removed.
|
||||||
**/
|
**/
|
||||||
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: KusamaRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: KusamaRuntimeProxyType, delay: u32 }>;
|
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: KusamaRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: KusamaRuntimeProxyType, delay: u32 }>;
|
||||||
|
/**
|
||||||
|
* A pure account has been created by new proxy with given
|
||||||
|
* disambiguation index and proxy type.
|
||||||
|
**/
|
||||||
|
PureCreated: AugmentedEvent<ApiType, [pure: AccountId32, who: AccountId32, proxyType: KusamaRuntimeProxyType, disambiguationIndex: u16], { pure: AccountId32, who: AccountId32, proxyType: KusamaRuntimeProxyType, disambiguationIndex: u16 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
@@ -968,40 +995,37 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
||||||
* it will not be emitted for staking rewards when they are added to stake.
|
* it will not be emitted for staking rewards when they are added to stake.
|
||||||
**/
|
**/
|
||||||
Bonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Bonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* An account has stopped participating as either a validator or nominator.
|
* An account has stopped participating as either a validator or nominator.
|
||||||
* \[stash\]
|
|
||||||
**/
|
**/
|
||||||
Chilled: AugmentedEvent<ApiType, [AccountId32]>;
|
Chilled: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The era payout has been set; the first balance is the validator-payout; the second is
|
* The era payout has been set; the first balance is the validator-payout; the second is
|
||||||
* the remainder from the maximum amount of reward.
|
* the remainder from the maximum amount of reward.
|
||||||
* \[era_index, validator_payout, remainder\]
|
|
||||||
**/
|
**/
|
||||||
EraPaid: AugmentedEvent<ApiType, [u32, u128, u128]>;
|
EraPaid: AugmentedEvent<ApiType, [eraIndex: u32, validatorPayout: u128, remainder: u128], { eraIndex: u32, validatorPayout: u128, remainder: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A nominator has been kicked from a validator. \[nominator, stash\]
|
* A nominator has been kicked from a validator.
|
||||||
**/
|
**/
|
||||||
Kicked: AugmentedEvent<ApiType, [AccountId32, AccountId32]>;
|
Kicked: AugmentedEvent<ApiType, [nominator: AccountId32, stash: AccountId32], { nominator: AccountId32, stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* An old slashing report from a prior era was discarded because it could
|
* An old slashing report from a prior era was discarded because it could
|
||||||
* not be processed. \[session_index\]
|
* not be processed.
|
||||||
**/
|
**/
|
||||||
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [u32]>;
|
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [sessionIndex: u32], { sessionIndex: u32 }>;
|
||||||
/**
|
/**
|
||||||
* The stakers' rewards are getting paid. \[era_index, validator_stash\]
|
* The stakers' rewards are getting paid.
|
||||||
**/
|
**/
|
||||||
PayoutStarted: AugmentedEvent<ApiType, [u32, AccountId32]>;
|
PayoutStarted: AugmentedEvent<ApiType, [eraIndex: u32, validatorStash: AccountId32], { eraIndex: u32, validatorStash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The nominator has been rewarded by this amount. \[stash, amount\]
|
* The nominator has been rewarded by this amount.
|
||||||
**/
|
**/
|
||||||
Rewarded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Rewarded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* One validator (and its nominators) has been slashed by the given amount.
|
* One staker (and potentially its nominators) has been slashed by the given amount.
|
||||||
* \[validator, amount\]
|
|
||||||
**/
|
**/
|
||||||
Slashed: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Slashed: AugmentedEvent<ApiType, [staker: AccountId32, amount: u128], { staker: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A new set of stakers was elected.
|
* A new set of stakers was elected.
|
||||||
**/
|
**/
|
||||||
@@ -1011,18 +1035,18 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* An account has unbonded this amount. \[stash, amount\]
|
* An account has unbonded this amount.
|
||||||
**/
|
**/
|
||||||
Unbonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Unbonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A validator has set their preferences.
|
* A validator has set their preferences.
|
||||||
**/
|
**/
|
||||||
ValidatorPrefsSet: AugmentedEvent<ApiType, [AccountId32, PalletStakingValidatorPrefs]>;
|
ValidatorPrefsSet: AugmentedEvent<ApiType, [stash: AccountId32, prefs: PalletStakingValidatorPrefs], { stash: AccountId32, prefs: PalletStakingValidatorPrefs }>;
|
||||||
/**
|
/**
|
||||||
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
||||||
* from the unlocking queue. \[stash, amount\]
|
* from the unlocking queue.
|
||||||
**/
|
**/
|
||||||
Withdrawn: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Withdrawn: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import type { BTreeMap, Bytes, Null, Option, U8aFixed, Vec, WrapperKeepOpaque, W
|
|||||||
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { EthereumAddress } from '@polkadot/types/interfaces/eth';
|
import type { EthereumAddress } from '@polkadot/types/interfaces/eth';
|
||||||
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, KusamaRuntimeSessionKeys, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletDemocracyPreimageStatus, PalletDemocracyReferendumInfo, PalletDemocracyReleases, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletGiltActiveGilt, PalletGiltActiveGiltsTotal, PalletGiltGiltBid, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletRecoveryActiveRecovery, PalletRecoveryRecoveryConfig, PalletSchedulerScheduledV3, PalletSocietyBid, PalletSocietyBidKind, PalletSocietyVote, PalletSocietyVouchingStatus, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTreasuryProposal, PalletVestingReleases, PalletVestingVestingInfo, PalletXcmQueryStatus, PalletXcmVersionMigrationStage, PolkadotCorePrimitivesInboundDownwardMessage, PolkadotCorePrimitivesInboundHrmpMessage, PolkadotParachainPrimitivesHrmpChannelId, PolkadotPrimitivesV2AssignmentAppPublic, PolkadotPrimitivesV2CandidateCommitments, PolkadotPrimitivesV2CoreOccupied, PolkadotPrimitivesV2DisputeState, PolkadotPrimitivesV2ScrapedOnChainVotes, PolkadotPrimitivesV2SessionInfo, PolkadotPrimitivesV2UpgradeGoAhead, PolkadotPrimitivesV2UpgradeRestriction, PolkadotPrimitivesV2ValidatorAppPublic, PolkadotRuntimeCommonClaimsStatementKind, PolkadotRuntimeCommonCrowdloanFundInfo, PolkadotRuntimeCommonParasRegistrarParaInfo, PolkadotRuntimeParachainsConfigurationHostConfiguration, PolkadotRuntimeParachainsHrmpHrmpChannel, PolkadotRuntimeParachainsHrmpHrmpOpenChannelRequest, PolkadotRuntimeParachainsInclusionAvailabilityBitfieldRecord, PolkadotRuntimeParachainsInclusionCandidatePendingAvailability, PolkadotRuntimeParachainsInitializerBufferedSessionChange, PolkadotRuntimeParachainsParasParaGenesisArgs, PolkadotRuntimeParachainsParasParaLifecycle, PolkadotRuntimeParachainsParasParaPastCodeMeta, PolkadotRuntimeParachainsParasPvfCheckActiveVoteState, PolkadotRuntimeParachainsSchedulerCoreAssignment, PolkadotRuntimeParachainsSchedulerParathreadClaimQueue, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails, XcmVersionedMultiLocation } from '@polkadot/types/lookup';
|
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, KusamaRuntimeSessionKeys, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletDemocracyPreimageStatus, PalletDemocracyReferendumInfo, PalletDemocracyReleases, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletFastUnstakeUnstakeRequest, PalletGiltActiveGilt, PalletGiltActiveGiltsTotal, PalletGiltGiltBid, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletRecoveryActiveRecovery, PalletRecoveryRecoveryConfig, PalletSchedulerScheduledV3, PalletSocietyBid, PalletSocietyBidKind, PalletSocietyVote, PalletSocietyVouchingStatus, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTreasuryProposal, PalletVestingReleases, PalletVestingVestingInfo, PalletXcmQueryStatus, PalletXcmVersionMigrationStage, PolkadotCorePrimitivesInboundDownwardMessage, PolkadotCorePrimitivesInboundHrmpMessage, PolkadotParachainPrimitivesHrmpChannelId, PolkadotPrimitivesV2AssignmentAppPublic, PolkadotPrimitivesV2CandidateCommitments, PolkadotPrimitivesV2CoreOccupied, PolkadotPrimitivesV2DisputeState, PolkadotPrimitivesV2ScrapedOnChainVotes, PolkadotPrimitivesV2SessionInfo, PolkadotPrimitivesV2UpgradeGoAhead, PolkadotPrimitivesV2UpgradeRestriction, PolkadotPrimitivesV2ValidatorAppPublic, PolkadotRuntimeCommonClaimsStatementKind, PolkadotRuntimeCommonCrowdloanFundInfo, PolkadotRuntimeCommonParasRegistrarParaInfo, PolkadotRuntimeParachainsConfigurationHostConfiguration, PolkadotRuntimeParachainsHrmpHrmpChannel, PolkadotRuntimeParachainsHrmpHrmpOpenChannelRequest, PolkadotRuntimeParachainsInclusionAvailabilityBitfieldRecord, PolkadotRuntimeParachainsInclusionCandidatePendingAvailability, PolkadotRuntimeParachainsInitializerBufferedSessionChange, PolkadotRuntimeParachainsParasParaGenesisArgs, PolkadotRuntimeParachainsParasParaLifecycle, PolkadotRuntimeParachainsParasParaPastCodeMeta, PolkadotRuntimeParachainsParasPvfCheckActiveVoteState, PolkadotRuntimeParachainsSchedulerCoreAssignment, PolkadotRuntimeParachainsSchedulerParathreadClaimQueue, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails, XcmVersionedMultiLocation } from '@polkadot/types/lookup';
|
||||||
import type { Observable } from '@polkadot/types/types';
|
import type { Observable } from '@polkadot/types/types';
|
||||||
|
|
||||||
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
||||||
@@ -543,6 +543,35 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Counter for the related counted storage map
|
||||||
|
**/
|
||||||
|
counterForQueue: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* Number of eras to check per block.
|
||||||
|
*
|
||||||
|
* If set to 0, this pallet does absolutely nothing.
|
||||||
|
*
|
||||||
|
* Based on the amount of weight available at `on_idle`, up to this many eras of a single
|
||||||
|
* nominator might be checked.
|
||||||
|
**/
|
||||||
|
erasToCheckPerBlock: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The current "head of the queue" being unstaked.
|
||||||
|
**/
|
||||||
|
head: AugmentedQuery<ApiType, () => Observable<Option<PalletFastUnstakeUnstakeRequest>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The map of all accounts wishing to be unstaked.
|
||||||
|
*
|
||||||
|
* Keeps track of `AccountId` wishing to unstake and it's corresponding deposit.
|
||||||
|
**/
|
||||||
|
queue: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<u128>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
||||||
|
/**
|
||||||
|
* Generic query
|
||||||
|
**/
|
||||||
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* The currently active gilts, indexed according to the order of creation.
|
* The currently active gilts, indexed according to the order of creation.
|
||||||
@@ -1590,16 +1619,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
* Mode of era forcing.
|
* Mode of era forcing.
|
||||||
**/
|
**/
|
||||||
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
|
||||||
* Number of eras to keep in history.
|
|
||||||
*
|
|
||||||
* Information is kept for eras in `[current_era - history_depth; current_era]`.
|
|
||||||
*
|
|
||||||
* Must be more than the number of eras delayed by session otherwise. I.e. active era must
|
|
||||||
* always be in history. I.e. `active_era > current_era - history_depth` must be
|
|
||||||
* guaranteed.
|
|
||||||
**/
|
|
||||||
historyDepth: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
|
||||||
/**
|
/**
|
||||||
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
||||||
* easy to initialize and the performance hit is minimal (we expect no more than four
|
* easy to initialize and the performance hit is minimal (we expect no more than four
|
||||||
|
|||||||
@@ -1408,6 +1408,49 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Control the operation of this pallet.
|
||||||
|
*
|
||||||
|
* Dispatch origin must be signed by the [`Config::ControlOrigin`].
|
||||||
|
**/
|
||||||
|
control: AugmentedSubmittable<(uncheckedErasToCheck: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
||||||
|
/**
|
||||||
|
* Deregister oneself from the fast-unstake.
|
||||||
|
*
|
||||||
|
* This is useful if one is registered, they are still waiting, and they change their mind.
|
||||||
|
*
|
||||||
|
* Note that the associated stash is still fully unbonded and chilled as a consequence of
|
||||||
|
* calling `register_fast_unstake`. This should probably be followed by a call to
|
||||||
|
* `Staking::rebond`.
|
||||||
|
**/
|
||||||
|
deregister: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Register oneself for fast-unstake.
|
||||||
|
*
|
||||||
|
* The dispatch origin of this call must be signed by the controller account, similar to
|
||||||
|
* `staking::unbond`.
|
||||||
|
*
|
||||||
|
* The stash associated with the origin must have no ongoing unlocking chunks. If
|
||||||
|
* successful, this will fully unbond and chill the stash. Then, it will enqueue the stash
|
||||||
|
* to be checked in further blocks.
|
||||||
|
*
|
||||||
|
* If by the time this is called, the stash is actually eligible for fast-unstake, then
|
||||||
|
* they are guaranteed to remain eligible, because the call will chill them as well.
|
||||||
|
*
|
||||||
|
* If the check works, the entire staking data is removed, i.e. the stash is fully
|
||||||
|
* unstaked.
|
||||||
|
*
|
||||||
|
* If the check fails, the stash remains chilled and waiting for being unbonded as in with
|
||||||
|
* the normal staking system, but they lose part of their unbonding chunks due to consuming
|
||||||
|
* the chain's resources.
|
||||||
|
**/
|
||||||
|
registerFastUnstake: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Generic tx
|
||||||
|
**/
|
||||||
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* Place a bid for a gilt to be issued.
|
* Place a bid for a gilt to be issued.
|
||||||
@@ -2546,10 +2589,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `proxy_type`: The permissions allowed for this proxy account.
|
* - `proxy_type`: The permissions allowed for this proxy account.
|
||||||
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
||||||
* zero.
|
* zero.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u32]>;
|
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -2568,12 +2607,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2595,36 +2628,27 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* same sender, with the same parameters.
|
* same sender, with the same parameters.
|
||||||
*
|
*
|
||||||
* Fails if there are insufficient funds to pay for deposit.
|
* Fails if there are insufficient funds to pay for deposit.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
* TODO: Might be over counting 1 read
|
|
||||||
**/
|
**/
|
||||||
anonymous: AugmentedSubmittable<(proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [KusamaRuntimeProxyType, u32, u16]>;
|
createPure: AugmentedSubmittable<(proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [KusamaRuntimeProxyType, u32, u16]>;
|
||||||
/**
|
/**
|
||||||
* Removes a previously spawned anonymous proxy.
|
* Removes a previously spawned pure proxy.
|
||||||
*
|
*
|
||||||
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
||||||
* inaccessible.
|
* inaccessible.
|
||||||
*
|
*
|
||||||
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
||||||
* `anonymous` with corresponding parameters.
|
* `pure` with corresponding parameters.
|
||||||
*
|
*
|
||||||
* - `spawner`: The account that originally called `anonymous` to create this account.
|
* - `spawner`: The account that originally called `pure` to create this account.
|
||||||
* - `index`: The disambiguation index originally passed to `anonymous`. Probably `0`.
|
* - `index`: The disambiguation index originally passed to `pure`. Probably `0`.
|
||||||
* - `proxy_type`: The proxy type originally passed to `anonymous`.
|
* - `proxy_type`: The proxy type originally passed to `pure`.
|
||||||
* - `height`: The height of the chain when the call to `anonymous` was processed.
|
* - `height`: The height of the chain when the call to `pure` was processed.
|
||||||
* - `ext_index`: The extrinsic index in which the call to `anonymous` was processed.
|
* - `ext_index`: The extrinsic index in which the call to `pure` was processed.
|
||||||
*
|
*
|
||||||
* Fails with `NoPermission` in case the caller is not a previously created anonymous
|
* Fails with `NoPermission` in case the caller is not a previously created pure
|
||||||
* account whose `anonymous` call has corresponding parameters.
|
* account whose `pure` call has corresponding parameters.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
killAnonymous: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
killPure: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Dispatch the given `call` from an account that the sender is authorised for through
|
* Dispatch the given `call` from an account that the sender is authorised for through
|
||||||
* `add_proxy`.
|
* `add_proxy`.
|
||||||
@@ -2637,10 +2661,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KusamaRuntimeProxyType> | null | Uint8Array | KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<KusamaRuntimeProxyType>, Call]>;
|
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KusamaRuntimeProxyType> | null | Uint8Array | KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<KusamaRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -2655,12 +2675,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KusamaRuntimeProxyType> | null | Uint8Array | KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<KusamaRuntimeProxyType>, Call]>;
|
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KusamaRuntimeProxyType> | null | Uint8Array | KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<KusamaRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -2674,12 +2688,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `delegate`: The account that previously announced the call.
|
* - `delegate`: The account that previously announced the call.
|
||||||
* - `call_hash`: The hash of the call to be made.
|
* - `call_hash`: The hash of the call to be made.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2693,12 +2701,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2706,12 +2708,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* The dispatch origin for this call must be _Signed_.
|
* The dispatch origin for this call must be _Signed_.
|
||||||
*
|
*
|
||||||
* WARNING: This may be called on accounts created by `anonymous`, however if done, then
|
* WARNING: This may be called on accounts created by `pure`, however if done, then
|
||||||
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
/**
|
/**
|
||||||
@@ -2722,10 +2720,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
||||||
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u32]>;
|
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KusamaRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -3640,31 +3634,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
||||||
/**
|
|
||||||
* Set `HistoryDepth` value. This function will delete any history information
|
|
||||||
* when `HistoryDepth` is reduced.
|
|
||||||
*
|
|
||||||
* Parameters:
|
|
||||||
* - `new_history_depth`: The new history depth you would like to set.
|
|
||||||
* - `era_items_deleted`: The number of items that will be deleted by this dispatch. This
|
|
||||||
* should report all the storage items that will be deleted by clearing old era history.
|
|
||||||
* Needed to report an accurate weight for the dispatch. Trusted by `Root` to report an
|
|
||||||
* accurate number.
|
|
||||||
*
|
|
||||||
* Origin must be root.
|
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* - E: Number of history depths removed, i.e. 10 -> 7 = 3
|
|
||||||
* - Weight: O(E)
|
|
||||||
* - DB Weight:
|
|
||||||
* - Reads: Current Era, History Depth
|
|
||||||
* - Writes: History Depth
|
|
||||||
* - Clear Prefix Each: Era Stakers, EraStakersClipped, ErasValidatorPrefs
|
|
||||||
* - Writes Each: ErasValidatorReward, ErasRewardPoints, ErasTotalStake,
|
|
||||||
* ErasStartSessionIndex
|
|
||||||
* # </weight>
|
|
||||||
**/
|
|
||||||
setHistoryDepth: AugmentedSubmittable<(newHistoryDepth: Compact<u32> | AnyNumber | Uint8Array, eraItemsDeleted: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, Compact<u32>]>;
|
|
||||||
/**
|
/**
|
||||||
* Set the validators who cannot be slashed (if any).
|
* Set the validators who cannot be slashed (if any).
|
||||||
*
|
*
|
||||||
@@ -3704,7 +3673,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
||||||
* This is checked only upon calling `validate`. Existing validators are not affected.
|
* This is checked only upon calling `validate`. Existing validators are not affected.
|
||||||
*
|
*
|
||||||
* Origin must be Root to call this function.
|
* RuntimeOrigin must be Root to call this function.
|
||||||
*
|
*
|
||||||
* NOTE: Existing nominators and validators will not be affected by this update.
|
* NOTE: Existing nominators and validators will not be affected by this update.
|
||||||
* to kick people under the new limits, `chill_other` should be called.
|
* to kick people under the new limits, `chill_other` should be called.
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/api-augment', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/api-augment', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -594,6 +594,29 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* Number of eras that staked funds must remain bonded for.
|
* Number of eras that staked funds must remain bonded for.
|
||||||
**/
|
**/
|
||||||
bondingDuration: u32 & AugmentedConst<ApiType>;
|
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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a migration.
|
||||||
|
* The test `reducing_history_depth_abrupt` shows this effect.
|
||||||
|
**/
|
||||||
|
historyDepth: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Maximum number of nominations per nominator.
|
* Maximum number of nominations per nominator.
|
||||||
**/
|
**/
|
||||||
@@ -606,8 +629,16 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
**/
|
**/
|
||||||
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The maximum number of `unlocking` chunks a [`StakingLedger`] can have. Effectively
|
* The maximum number of `unlocking` chunks a [`StakingLedger`] can
|
||||||
* determines how many unique eras a staker may be unbonding in.
|
* 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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a runtime
|
||||||
|
* migration. The test `reducing_max_unlocking_chunks_abrupt` shows
|
||||||
|
* this effect.
|
||||||
**/
|
**/
|
||||||
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -570,6 +570,38 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedError<ApiType>;
|
[key: string]: AugmentedError<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* The provided un-staker is already in Head, and cannot deregister.
|
||||||
|
**/
|
||||||
|
AlreadyHead: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has already been queued.
|
||||||
|
**/
|
||||||
|
AlreadyQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The call is not allowed at this point because the pallet is not active.
|
||||||
|
**/
|
||||||
|
CallNotAllowed: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided Controller account was not found.
|
||||||
|
*
|
||||||
|
* This means that the given account is not bonded.
|
||||||
|
**/
|
||||||
|
NotController: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has active unlocking chunks.
|
||||||
|
**/
|
||||||
|
NotFullyBonded: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided un-staker is not in the `Queue`.
|
||||||
|
**/
|
||||||
|
NotQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Generic error
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedError<ApiType>;
|
||||||
|
};
|
||||||
grandpa: {
|
grandpa: {
|
||||||
/**
|
/**
|
||||||
* Attempt to signal GRANDPA change with one already pending.
|
* Attempt to signal GRANDPA change with one already pending.
|
||||||
@@ -1495,6 +1527,10 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* A nomination target was supplied that was blocked or otherwise not a validator.
|
* A nomination target was supplied that was blocked or otherwise not a validator.
|
||||||
**/
|
**/
|
||||||
BadTarget: AugmentedError<ApiType>;
|
BadTarget: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Some bound is not met.
|
||||||
|
**/
|
||||||
|
BoundNotMet: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
||||||
**/
|
**/
|
||||||
|
|||||||
@@ -377,6 +377,33 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* A staker was partially checked for the given eras, but the process did not finish.
|
||||||
|
**/
|
||||||
|
Checking: AugmentedEvent<ApiType, [stash: AccountId32, eras: Vec<u32>], { stash: AccountId32, eras: Vec<u32> }>;
|
||||||
|
/**
|
||||||
|
* Some internal error happened while migrating stash. They are removed as head as a
|
||||||
|
* consequence.
|
||||||
|
**/
|
||||||
|
Errored: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
|
/**
|
||||||
|
* An internal error happened. Operations will be paused now.
|
||||||
|
**/
|
||||||
|
InternalError: AugmentedEvent<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* A staker was slashed for requesting fast-unstake whilst being exposed.
|
||||||
|
**/
|
||||||
|
Slashed: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
|
/**
|
||||||
|
* A staker was unstaked.
|
||||||
|
**/
|
||||||
|
Unstaked: AugmentedEvent<ApiType, [stash: AccountId32, result: Result<Null, SpRuntimeDispatchError>], { stash: AccountId32, result: Result<Null, SpRuntimeDispatchError> }>;
|
||||||
|
/**
|
||||||
|
* Generic event
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
|
};
|
||||||
grandpa: {
|
grandpa: {
|
||||||
/**
|
/**
|
||||||
* New authority set has been applied.
|
* New authority set has been applied.
|
||||||
@@ -756,11 +783,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* An announcement was placed to make a call in the future.
|
* An announcement was placed to make a call in the future.
|
||||||
**/
|
**/
|
||||||
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
||||||
/**
|
|
||||||
* Anonymous account has been created by new proxy with given
|
|
||||||
* disambiguation index and proxy type.
|
|
||||||
**/
|
|
||||||
AnonymousCreated: AugmentedEvent<ApiType, [anonymous: AccountId32, who: AccountId32, proxyType: PolkadotRuntimeProxyType, disambiguationIndex: u16], { anonymous: AccountId32, who: AccountId32, proxyType: PolkadotRuntimeProxyType, disambiguationIndex: u16 }>;
|
|
||||||
/**
|
/**
|
||||||
* A proxy was added.
|
* A proxy was added.
|
||||||
**/
|
**/
|
||||||
@@ -773,6 +795,11 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* A proxy was removed.
|
* A proxy was removed.
|
||||||
**/
|
**/
|
||||||
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: PolkadotRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: PolkadotRuntimeProxyType, delay: u32 }>;
|
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: PolkadotRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: PolkadotRuntimeProxyType, delay: u32 }>;
|
||||||
|
/**
|
||||||
|
* A pure account has been created by new proxy with given
|
||||||
|
* disambiguation index and proxy type.
|
||||||
|
**/
|
||||||
|
PureCreated: AugmentedEvent<ApiType, [pure: AccountId32, who: AccountId32, proxyType: PolkadotRuntimeProxyType, disambiguationIndex: u16], { pure: AccountId32, who: AccountId32, proxyType: PolkadotRuntimeProxyType, disambiguationIndex: u16 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
@@ -843,40 +870,37 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
||||||
* it will not be emitted for staking rewards when they are added to stake.
|
* it will not be emitted for staking rewards when they are added to stake.
|
||||||
**/
|
**/
|
||||||
Bonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Bonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* An account has stopped participating as either a validator or nominator.
|
* An account has stopped participating as either a validator or nominator.
|
||||||
* \[stash\]
|
|
||||||
**/
|
**/
|
||||||
Chilled: AugmentedEvent<ApiType, [AccountId32]>;
|
Chilled: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The era payout has been set; the first balance is the validator-payout; the second is
|
* The era payout has been set; the first balance is the validator-payout; the second is
|
||||||
* the remainder from the maximum amount of reward.
|
* the remainder from the maximum amount of reward.
|
||||||
* \[era_index, validator_payout, remainder\]
|
|
||||||
**/
|
**/
|
||||||
EraPaid: AugmentedEvent<ApiType, [u32, u128, u128]>;
|
EraPaid: AugmentedEvent<ApiType, [eraIndex: u32, validatorPayout: u128, remainder: u128], { eraIndex: u32, validatorPayout: u128, remainder: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A nominator has been kicked from a validator. \[nominator, stash\]
|
* A nominator has been kicked from a validator.
|
||||||
**/
|
**/
|
||||||
Kicked: AugmentedEvent<ApiType, [AccountId32, AccountId32]>;
|
Kicked: AugmentedEvent<ApiType, [nominator: AccountId32, stash: AccountId32], { nominator: AccountId32, stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* An old slashing report from a prior era was discarded because it could
|
* An old slashing report from a prior era was discarded because it could
|
||||||
* not be processed. \[session_index\]
|
* not be processed.
|
||||||
**/
|
**/
|
||||||
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [u32]>;
|
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [sessionIndex: u32], { sessionIndex: u32 }>;
|
||||||
/**
|
/**
|
||||||
* The stakers' rewards are getting paid. \[era_index, validator_stash\]
|
* The stakers' rewards are getting paid.
|
||||||
**/
|
**/
|
||||||
PayoutStarted: AugmentedEvent<ApiType, [u32, AccountId32]>;
|
PayoutStarted: AugmentedEvent<ApiType, [eraIndex: u32, validatorStash: AccountId32], { eraIndex: u32, validatorStash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The nominator has been rewarded by this amount. \[stash, amount\]
|
* The nominator has been rewarded by this amount.
|
||||||
**/
|
**/
|
||||||
Rewarded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Rewarded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* One validator (and its nominators) has been slashed by the given amount.
|
* One staker (and potentially its nominators) has been slashed by the given amount.
|
||||||
* \[validator, amount\]
|
|
||||||
**/
|
**/
|
||||||
Slashed: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Slashed: AugmentedEvent<ApiType, [staker: AccountId32, amount: u128], { staker: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A new set of stakers was elected.
|
* A new set of stakers was elected.
|
||||||
**/
|
**/
|
||||||
@@ -886,18 +910,18 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* An account has unbonded this amount. \[stash, amount\]
|
* An account has unbonded this amount.
|
||||||
**/
|
**/
|
||||||
Unbonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Unbonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A validator has set their preferences.
|
* A validator has set their preferences.
|
||||||
**/
|
**/
|
||||||
ValidatorPrefsSet: AugmentedEvent<ApiType, [AccountId32, PalletStakingValidatorPrefs]>;
|
ValidatorPrefsSet: AugmentedEvent<ApiType, [stash: AccountId32, prefs: PalletStakingValidatorPrefs], { stash: AccountId32, prefs: PalletStakingValidatorPrefs }>;
|
||||||
/**
|
/**
|
||||||
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
||||||
* from the unlocking queue. \[stash, amount\]
|
* from the unlocking queue.
|
||||||
**/
|
**/
|
||||||
Withdrawn: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Withdrawn: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import type { BTreeMap, Bytes, Null, Option, U8aFixed, Vec, WrapperKeepOpaque, W
|
|||||||
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { EthereumAddress } from '@polkadot/types/interfaces/eth';
|
import type { EthereumAddress } from '@polkadot/types/interfaces/eth';
|
||||||
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletDemocracyPreimageStatus, PalletDemocracyReferendumInfo, PalletDemocracyReleases, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletSchedulerScheduledV3, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTreasuryProposal, PalletVestingReleases, PalletVestingVestingInfo, PalletXcmQueryStatus, PalletXcmVersionMigrationStage, PolkadotCorePrimitivesInboundDownwardMessage, PolkadotCorePrimitivesInboundHrmpMessage, PolkadotParachainPrimitivesHrmpChannelId, PolkadotPrimitivesV2AssignmentAppPublic, PolkadotPrimitivesV2CandidateCommitments, PolkadotPrimitivesV2CoreOccupied, PolkadotPrimitivesV2DisputeState, PolkadotPrimitivesV2ScrapedOnChainVotes, PolkadotPrimitivesV2SessionInfo, PolkadotPrimitivesV2UpgradeGoAhead, PolkadotPrimitivesV2UpgradeRestriction, PolkadotPrimitivesV2ValidatorAppPublic, PolkadotRuntimeCommonClaimsStatementKind, PolkadotRuntimeCommonCrowdloanFundInfo, PolkadotRuntimeCommonParasRegistrarParaInfo, PolkadotRuntimeParachainsConfigurationHostConfiguration, PolkadotRuntimeParachainsHrmpHrmpChannel, PolkadotRuntimeParachainsHrmpHrmpOpenChannelRequest, PolkadotRuntimeParachainsInclusionAvailabilityBitfieldRecord, PolkadotRuntimeParachainsInclusionCandidatePendingAvailability, PolkadotRuntimeParachainsInitializerBufferedSessionChange, PolkadotRuntimeParachainsParasParaGenesisArgs, PolkadotRuntimeParachainsParasParaLifecycle, PolkadotRuntimeParachainsParasParaPastCodeMeta, PolkadotRuntimeParachainsParasPvfCheckActiveVoteState, PolkadotRuntimeParachainsSchedulerCoreAssignment, PolkadotRuntimeParachainsSchedulerParathreadClaimQueue, PolkadotRuntimeSessionKeys, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails, XcmVersionedMultiLocation } from '@polkadot/types/lookup';
|
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletDemocracyPreimageStatus, PalletDemocracyReferendumInfo, PalletDemocracyReleases, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletFastUnstakeUnstakeRequest, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletSchedulerScheduledV3, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTreasuryProposal, PalletVestingReleases, PalletVestingVestingInfo, PalletXcmQueryStatus, PalletXcmVersionMigrationStage, PolkadotCorePrimitivesInboundDownwardMessage, PolkadotCorePrimitivesInboundHrmpMessage, PolkadotParachainPrimitivesHrmpChannelId, PolkadotPrimitivesV2AssignmentAppPublic, PolkadotPrimitivesV2CandidateCommitments, PolkadotPrimitivesV2CoreOccupied, PolkadotPrimitivesV2DisputeState, PolkadotPrimitivesV2ScrapedOnChainVotes, PolkadotPrimitivesV2SessionInfo, PolkadotPrimitivesV2UpgradeGoAhead, PolkadotPrimitivesV2UpgradeRestriction, PolkadotPrimitivesV2ValidatorAppPublic, PolkadotRuntimeCommonClaimsStatementKind, PolkadotRuntimeCommonCrowdloanFundInfo, PolkadotRuntimeCommonParasRegistrarParaInfo, PolkadotRuntimeParachainsConfigurationHostConfiguration, PolkadotRuntimeParachainsHrmpHrmpChannel, PolkadotRuntimeParachainsHrmpHrmpOpenChannelRequest, PolkadotRuntimeParachainsInclusionAvailabilityBitfieldRecord, PolkadotRuntimeParachainsInclusionCandidatePendingAvailability, PolkadotRuntimeParachainsInitializerBufferedSessionChange, PolkadotRuntimeParachainsParasParaGenesisArgs, PolkadotRuntimeParachainsParasParaLifecycle, PolkadotRuntimeParachainsParasParaPastCodeMeta, PolkadotRuntimeParachainsParasPvfCheckActiveVoteState, PolkadotRuntimeParachainsSchedulerCoreAssignment, PolkadotRuntimeParachainsSchedulerParathreadClaimQueue, PolkadotRuntimeSessionKeys, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails, XcmVersionedMultiLocation } from '@polkadot/types/lookup';
|
||||||
import type { Observable } from '@polkadot/types/types';
|
import type { Observable } from '@polkadot/types/types';
|
||||||
|
|
||||||
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
||||||
@@ -543,6 +543,35 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Counter for the related counted storage map
|
||||||
|
**/
|
||||||
|
counterForQueue: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* Number of eras to check per block.
|
||||||
|
*
|
||||||
|
* If set to 0, this pallet does absolutely nothing.
|
||||||
|
*
|
||||||
|
* Based on the amount of weight available at `on_idle`, up to this many eras of a single
|
||||||
|
* nominator might be checked.
|
||||||
|
**/
|
||||||
|
erasToCheckPerBlock: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The current "head of the queue" being unstaked.
|
||||||
|
**/
|
||||||
|
head: AugmentedQuery<ApiType, () => Observable<Option<PalletFastUnstakeUnstakeRequest>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The map of all accounts wishing to be unstaked.
|
||||||
|
*
|
||||||
|
* Keeps track of `AccountId` wishing to unstake and it's corresponding deposit.
|
||||||
|
**/
|
||||||
|
queue: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<u128>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
||||||
|
/**
|
||||||
|
* Generic query
|
||||||
|
**/
|
||||||
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
|
};
|
||||||
grandpa: {
|
grandpa: {
|
||||||
/**
|
/**
|
||||||
* The number of changes (both in terms of keys and underlying economic responsibilities)
|
* The number of changes (both in terms of keys and underlying economic responsibilities)
|
||||||
@@ -1470,16 +1499,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
* Mode of era forcing.
|
* Mode of era forcing.
|
||||||
**/
|
**/
|
||||||
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
|
||||||
* Number of eras to keep in history.
|
|
||||||
*
|
|
||||||
* Information is kept for eras in `[current_era - history_depth; current_era]`.
|
|
||||||
*
|
|
||||||
* Must be more than the number of eras delayed by session otherwise. I.e. active era must
|
|
||||||
* always be in history. I.e. `active_era > current_era - history_depth` must be
|
|
||||||
* guaranteed.
|
|
||||||
**/
|
|
||||||
historyDepth: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
|
||||||
/**
|
/**
|
||||||
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
||||||
* easy to initialize and the performance hit is minimal (we expect no more than four
|
* easy to initialize and the performance hit is minimal (we expect no more than four
|
||||||
|
|||||||
@@ -1408,6 +1408,49 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Control the operation of this pallet.
|
||||||
|
*
|
||||||
|
* Dispatch origin must be signed by the [`Config::ControlOrigin`].
|
||||||
|
**/
|
||||||
|
control: AugmentedSubmittable<(uncheckedErasToCheck: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
||||||
|
/**
|
||||||
|
* Deregister oneself from the fast-unstake.
|
||||||
|
*
|
||||||
|
* This is useful if one is registered, they are still waiting, and they change their mind.
|
||||||
|
*
|
||||||
|
* Note that the associated stash is still fully unbonded and chilled as a consequence of
|
||||||
|
* calling `register_fast_unstake`. This should probably be followed by a call to
|
||||||
|
* `Staking::rebond`.
|
||||||
|
**/
|
||||||
|
deregister: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Register oneself for fast-unstake.
|
||||||
|
*
|
||||||
|
* The dispatch origin of this call must be signed by the controller account, similar to
|
||||||
|
* `staking::unbond`.
|
||||||
|
*
|
||||||
|
* The stash associated with the origin must have no ongoing unlocking chunks. If
|
||||||
|
* successful, this will fully unbond and chill the stash. Then, it will enqueue the stash
|
||||||
|
* to be checked in further blocks.
|
||||||
|
*
|
||||||
|
* If by the time this is called, the stash is actually eligible for fast-unstake, then
|
||||||
|
* they are guaranteed to remain eligible, because the call will chill them as well.
|
||||||
|
*
|
||||||
|
* If the check works, the entire staking data is removed, i.e. the stash is fully
|
||||||
|
* unstaked.
|
||||||
|
*
|
||||||
|
* If the check fails, the stash remains chilled and waiting for being unbonded as in with
|
||||||
|
* the normal staking system, but they lose part of their unbonding chunks due to consuming
|
||||||
|
* the chain's resources.
|
||||||
|
**/
|
||||||
|
registerFastUnstake: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Generic tx
|
||||||
|
**/
|
||||||
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
|
};
|
||||||
grandpa: {
|
grandpa: {
|
||||||
/**
|
/**
|
||||||
* Note that the current authority set of the GRANDPA finality gadget has stalled.
|
* Note that the current authority set of the GRANDPA finality gadget has stalled.
|
||||||
@@ -2495,10 +2538,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `proxy_type`: The permissions allowed for this proxy account.
|
* - `proxy_type`: The permissions allowed for this proxy account.
|
||||||
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
||||||
* zero.
|
* zero.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u32]>;
|
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -2517,12 +2556,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2544,36 +2577,27 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* same sender, with the same parameters.
|
* same sender, with the same parameters.
|
||||||
*
|
*
|
||||||
* Fails if there are insufficient funds to pay for deposit.
|
* Fails if there are insufficient funds to pay for deposit.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
* TODO: Might be over counting 1 read
|
|
||||||
**/
|
**/
|
||||||
anonymous: AugmentedSubmittable<(proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PolkadotRuntimeProxyType, u32, u16]>;
|
createPure: AugmentedSubmittable<(proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PolkadotRuntimeProxyType, u32, u16]>;
|
||||||
/**
|
/**
|
||||||
* Removes a previously spawned anonymous proxy.
|
* Removes a previously spawned pure proxy.
|
||||||
*
|
*
|
||||||
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
||||||
* inaccessible.
|
* inaccessible.
|
||||||
*
|
*
|
||||||
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
||||||
* `anonymous` with corresponding parameters.
|
* `pure` with corresponding parameters.
|
||||||
*
|
*
|
||||||
* - `spawner`: The account that originally called `anonymous` to create this account.
|
* - `spawner`: The account that originally called `pure` to create this account.
|
||||||
* - `index`: The disambiguation index originally passed to `anonymous`. Probably `0`.
|
* - `index`: The disambiguation index originally passed to `pure`. Probably `0`.
|
||||||
* - `proxy_type`: The proxy type originally passed to `anonymous`.
|
* - `proxy_type`: The proxy type originally passed to `pure`.
|
||||||
* - `height`: The height of the chain when the call to `anonymous` was processed.
|
* - `height`: The height of the chain when the call to `pure` was processed.
|
||||||
* - `ext_index`: The extrinsic index in which the call to `anonymous` was processed.
|
* - `ext_index`: The extrinsic index in which the call to `pure` was processed.
|
||||||
*
|
*
|
||||||
* Fails with `NoPermission` in case the caller is not a previously created anonymous
|
* Fails with `NoPermission` in case the caller is not a previously created pure
|
||||||
* account whose `anonymous` call has corresponding parameters.
|
* account whose `pure` call has corresponding parameters.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
killAnonymous: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
killPure: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Dispatch the given `call` from an account that the sender is authorised for through
|
* Dispatch the given `call` from an account that the sender is authorised for through
|
||||||
* `add_proxy`.
|
* `add_proxy`.
|
||||||
@@ -2586,10 +2610,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<PolkadotRuntimeProxyType> | null | Uint8Array | PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<PolkadotRuntimeProxyType>, Call]>;
|
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<PolkadotRuntimeProxyType> | null | Uint8Array | PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<PolkadotRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -2604,12 +2624,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<PolkadotRuntimeProxyType> | null | Uint8Array | PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<PolkadotRuntimeProxyType>, Call]>;
|
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<PolkadotRuntimeProxyType> | null | Uint8Array | PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<PolkadotRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -2623,12 +2637,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `delegate`: The account that previously announced the call.
|
* - `delegate`: The account that previously announced the call.
|
||||||
* - `call_hash`: The hash of the call to be made.
|
* - `call_hash`: The hash of the call to be made.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2642,12 +2650,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2655,12 +2657,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* The dispatch origin for this call must be _Signed_.
|
* The dispatch origin for this call must be _Signed_.
|
||||||
*
|
*
|
||||||
* WARNING: This may be called on accounts created by `anonymous`, however if done, then
|
* WARNING: This may be called on accounts created by `pure`, however if done, then
|
||||||
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
/**
|
/**
|
||||||
@@ -2671,10 +2669,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
||||||
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u32]>;
|
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: PolkadotRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PolkadotRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -3136,31 +3130,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
||||||
/**
|
|
||||||
* Set `HistoryDepth` value. This function will delete any history information
|
|
||||||
* when `HistoryDepth` is reduced.
|
|
||||||
*
|
|
||||||
* Parameters:
|
|
||||||
* - `new_history_depth`: The new history depth you would like to set.
|
|
||||||
* - `era_items_deleted`: The number of items that will be deleted by this dispatch. This
|
|
||||||
* should report all the storage items that will be deleted by clearing old era history.
|
|
||||||
* Needed to report an accurate weight for the dispatch. Trusted by `Root` to report an
|
|
||||||
* accurate number.
|
|
||||||
*
|
|
||||||
* Origin must be root.
|
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* - E: Number of history depths removed, i.e. 10 -> 7 = 3
|
|
||||||
* - Weight: O(E)
|
|
||||||
* - DB Weight:
|
|
||||||
* - Reads: Current Era, History Depth
|
|
||||||
* - Writes: History Depth
|
|
||||||
* - Clear Prefix Each: Era Stakers, EraStakersClipped, ErasValidatorPrefs
|
|
||||||
* - Writes Each: ErasValidatorReward, ErasRewardPoints, ErasTotalStake,
|
|
||||||
* ErasStartSessionIndex
|
|
||||||
* # </weight>
|
|
||||||
**/
|
|
||||||
setHistoryDepth: AugmentedSubmittable<(newHistoryDepth: Compact<u32> | AnyNumber | Uint8Array, eraItemsDeleted: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, Compact<u32>]>;
|
|
||||||
/**
|
/**
|
||||||
* Set the validators who cannot be slashed (if any).
|
* Set the validators who cannot be slashed (if any).
|
||||||
*
|
*
|
||||||
@@ -3200,7 +3169,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
||||||
* This is checked only upon calling `validate`. Existing validators are not affected.
|
* This is checked only upon calling `validate`. Existing validators are not affected.
|
||||||
*
|
*
|
||||||
* Origin must be Root to call this function.
|
* RuntimeOrigin must be Root to call this function.
|
||||||
*
|
*
|
||||||
* NOTE: Existing nominators and validators will not be affected by this update.
|
* NOTE: Existing nominators and validators will not be affected by this update.
|
||||||
* to kick people under the new limits, `chill_other` should be called.
|
* to kick people under the new limits, `chill_other` should be called.
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import '@polkadot/api-base/types/consts';
|
|||||||
import type { ApiTypes, AugmentedConst } from '@polkadot/api-base/types';
|
import type { ApiTypes, AugmentedConst } from '@polkadot/api-base/types';
|
||||||
import type { Option, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
import type { Option, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
||||||
import type { Codec, ITuple } from '@polkadot/types-codec/types';
|
import type { Codec, ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { Perbill, Percent, Permill, Weight } from '@polkadot/types/interfaces/runtime';
|
import type { Perbill, Percent, Permill } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportPalletId, FrameSystemLimitsBlockLength, FrameSystemLimitsBlockWeights, PalletContractsSchedule, PalletReferendaTrackInfo, SpVersionRuntimeVersion, SpWeightsRuntimeDbWeight } from '@polkadot/types/lookup';
|
import type { FrameSupportPalletId, FrameSystemLimitsBlockLength, FrameSystemLimitsBlockWeights, PalletContractsSchedule, PalletReferendaTrackInfo, SpVersionRuntimeVersion, SpWeightsRuntimeDbWeight, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
|
||||||
|
|
||||||
export type __AugmentedConst<ApiType extends ApiTypes> = AugmentedConst<ApiType>;
|
export type __AugmentedConst<ApiType extends ApiTypes> = AugmentedConst<ApiType>;
|
||||||
|
|
||||||
@@ -110,58 +110,6 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: Codec;
|
[key: string]: Codec;
|
||||||
};
|
};
|
||||||
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
|
|
||||||
* the procedure given above, then the constant ratio is equal to 2.
|
|
||||||
* - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to
|
|
||||||
* 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.
|
|
||||||
**/
|
|
||||||
bagThresholds: Vec<u64> & AugmentedConst<ApiType>;
|
|
||||||
/**
|
|
||||||
* Generic const
|
|
||||||
**/
|
|
||||||
[key: string]: Codec;
|
|
||||||
};
|
|
||||||
balances: {
|
balances: {
|
||||||
/**
|
/**
|
||||||
* The minimum amount required to keep an account open.
|
* The minimum amount required to keep an account open.
|
||||||
@@ -243,27 +191,6 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
[key: string]: Codec;
|
[key: string]: Codec;
|
||||||
};
|
};
|
||||||
contracts: {
|
contracts: {
|
||||||
/**
|
|
||||||
* The weight per byte of code that is charged when loading a contract from storage.
|
|
||||||
*
|
|
||||||
* Currently, FRAME only charges fees for computation incurred but not for PoV
|
|
||||||
* consumption caused for storage access. This is usually not exploitable because
|
|
||||||
* accessing storage carries some substantial weight costs, too. However in case
|
|
||||||
* of contract code very much PoV consumption can be caused while consuming very little
|
|
||||||
* computation. This could be used to keep the chain busy without paying the
|
|
||||||
* proper fee for it. Until this is resolved we charge from the weight meter for
|
|
||||||
* contract access.
|
|
||||||
*
|
|
||||||
* For more information check out: <https://github.com/paritytech/substrate/issues/10301>
|
|
||||||
*
|
|
||||||
* [`DefaultContractAccessWeight`] is a safe default to be used for Polkadot or Kusama
|
|
||||||
* parachains.
|
|
||||||
*
|
|
||||||
* # Note
|
|
||||||
*
|
|
||||||
* This is only relevant for parachains. Set to zero in case of a standalone chain.
|
|
||||||
**/
|
|
||||||
contractAccessWeight: Weight & AugmentedConst<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* The maximum number of contracts that can be pending for deletion.
|
* The maximum number of contracts that can be pending for deletion.
|
||||||
*
|
*
|
||||||
@@ -290,7 +217,7 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* weight that is left for transactions. See [`Self::DeletionQueueDepth`] for more
|
* weight that is left for transactions. See [`Self::DeletionQueueDepth`] for more
|
||||||
* information about the deletion queue.
|
* information about the deletion queue.
|
||||||
**/
|
**/
|
||||||
deletionWeightLimit: Weight & AugmentedConst<ApiType>;
|
deletionWeightLimit: SpWeightsWeightV2Weight & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The amount of balance a caller has to pay for each byte of storage.
|
* The amount of balance a caller has to pay for each byte of storage.
|
||||||
*
|
*
|
||||||
@@ -363,6 +290,14 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* How often (in blocks) new public referenda are launched.
|
* How often (in blocks) new public referenda are launched.
|
||||||
**/
|
**/
|
||||||
launchPeriod: u32 & AugmentedConst<ApiType>;
|
launchPeriod: u32 & AugmentedConst<ApiType>;
|
||||||
|
/**
|
||||||
|
* The maximum number of items which can be blacklisted.
|
||||||
|
**/
|
||||||
|
maxBlacklisted: u32 & AugmentedConst<ApiType>;
|
||||||
|
/**
|
||||||
|
* The maximum number of deposits a public proposal may have at any time.
|
||||||
|
**/
|
||||||
|
maxDeposits: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The maximum number of public proposals that can exist at any time.
|
* The maximum number of public proposals that can exist at any time.
|
||||||
**/
|
**/
|
||||||
@@ -378,10 +313,6 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* The minimum amount to be used as a deposit for a public referendum proposal.
|
* The minimum amount to be used as a deposit for a public referendum proposal.
|
||||||
**/
|
**/
|
||||||
minimumDeposit: u128 & AugmentedConst<ApiType>;
|
minimumDeposit: u128 & AugmentedConst<ApiType>;
|
||||||
/**
|
|
||||||
* The amount of balance that must be deposited per byte of preimage stored.
|
|
||||||
**/
|
|
||||||
preimageByteDeposit: u128 & AugmentedConst<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* The minimum period of vote locking.
|
* The minimum period of vote locking.
|
||||||
*
|
*
|
||||||
@@ -421,7 +352,7 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
maxElectingVoters: u32 & AugmentedConst<ApiType>;
|
maxElectingVoters: u32 & AugmentedConst<ApiType>;
|
||||||
minerMaxLength: u32 & AugmentedConst<ApiType>;
|
minerMaxLength: u32 & AugmentedConst<ApiType>;
|
||||||
minerMaxVotesPerVoter: u32 & AugmentedConst<ApiType>;
|
minerMaxVotesPerVoter: u32 & AugmentedConst<ApiType>;
|
||||||
minerMaxWeight: Weight & AugmentedConst<ApiType>;
|
minerMaxWeight: SpWeightsWeightV2Weight & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The priority of the unsigned transaction submitted in the unsigned-phase
|
* The priority of the unsigned transaction submitted in the unsigned-phase
|
||||||
**/
|
**/
|
||||||
@@ -466,7 +397,7 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* this pallet), then [`MinerConfig::solution_weight`] is used to compare against
|
* this pallet), then [`MinerConfig::solution_weight`] is used to compare against
|
||||||
* this value.
|
* this value.
|
||||||
**/
|
**/
|
||||||
signedMaxWeight: Weight & AugmentedConst<ApiType>;
|
signedMaxWeight: SpWeightsWeightV2Weight & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Duration of the signed phase.
|
* Duration of the signed phase.
|
||||||
**/
|
**/
|
||||||
@@ -867,13 +798,11 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
};
|
};
|
||||||
scheduler: {
|
scheduler: {
|
||||||
/**
|
/**
|
||||||
* The maximum weight that may be scheduled per block for any dispatchables of less
|
* The maximum weight that may be scheduled per block for any dispatchables.
|
||||||
* priority than `schedule::HARD_DEADLINE`.
|
|
||||||
**/
|
**/
|
||||||
maximumWeight: Weight & AugmentedConst<ApiType>;
|
maximumWeight: SpWeightsWeightV2Weight & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The maximum number of scheduled calls in the queue for a single block.
|
* The maximum number of scheduled calls in the queue for a single block.
|
||||||
* Not strictly enforced, but used for weight estimation.
|
|
||||||
**/
|
**/
|
||||||
maxScheduledPerBlock: u32 & AugmentedConst<ApiType>;
|
maxScheduledPerBlock: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
@@ -930,6 +859,29 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
* Number of eras that staked funds must remain bonded for.
|
* Number of eras that staked funds must remain bonded for.
|
||||||
**/
|
**/
|
||||||
bondingDuration: u32 & AugmentedConst<ApiType>;
|
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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a migration.
|
||||||
|
* The test `reducing_history_depth_abrupt` shows this effect.
|
||||||
|
**/
|
||||||
|
historyDepth: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Maximum number of nominations per nominator.
|
* Maximum number of nominations per nominator.
|
||||||
**/
|
**/
|
||||||
@@ -942,8 +894,16 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
**/
|
**/
|
||||||
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
maxNominatorRewardedPerValidator: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The maximum number of `unlocking` chunks a [`StakingLedger`] can have. Effectively
|
* The maximum number of `unlocking` chunks a [`StakingLedger`] can
|
||||||
* determines how many unique eras a staker may be unbonding in.
|
* 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
|
||||||
|
* `StakingLedger` and will need to be handled properly in a runtime
|
||||||
|
* migration. The test `reducing_max_unlocking_chunks_abrupt` shows
|
||||||
|
* this effect.
|
||||||
**/
|
**/
|
||||||
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
maxUnlockingChunks: u32 & AugmentedConst<ApiType>;
|
||||||
/**
|
/**
|
||||||
@@ -1194,5 +1154,57 @@ declare module '@polkadot/api-base/types/consts' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: Codec;
|
[key: string]: Codec;
|
||||||
};
|
};
|
||||||
|
voterList: {
|
||||||
|
/**
|
||||||
|
* 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
|
||||||
|
* the procedure given above, then the constant ratio is equal to 2.
|
||||||
|
* - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to
|
||||||
|
* 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.
|
||||||
|
**/
|
||||||
|
bagThresholds: Vec<u64> & AugmentedConst<ApiType>;
|
||||||
|
/**
|
||||||
|
* Generic const
|
||||||
|
**/
|
||||||
|
[key: string]: Codec;
|
||||||
|
};
|
||||||
} // AugmentedConsts
|
} // AugmentedConsts
|
||||||
} // declare module
|
} // declare module
|
||||||
|
|||||||
@@ -292,16 +292,6 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedError<ApiType>;
|
[key: string]: AugmentedError<ApiType>;
|
||||||
};
|
};
|
||||||
bagsList: {
|
|
||||||
/**
|
|
||||||
* A error in the list interface implementation.
|
|
||||||
**/
|
|
||||||
List: AugmentedError<ApiType>;
|
|
||||||
/**
|
|
||||||
* Generic error
|
|
||||||
**/
|
|
||||||
[key: string]: AugmentedError<ApiType>;
|
|
||||||
};
|
|
||||||
balances: {
|
balances: {
|
||||||
/**
|
/**
|
||||||
* Beneficiary account must pre-exist
|
* Beneficiary account must pre-exist
|
||||||
@@ -662,18 +652,10 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* Identity may not veto a proposal twice
|
* Identity may not veto a proposal twice
|
||||||
**/
|
**/
|
||||||
AlreadyVetoed: AugmentedError<ApiType>;
|
AlreadyVetoed: AugmentedError<ApiType>;
|
||||||
/**
|
|
||||||
* Preimage already noted
|
|
||||||
**/
|
|
||||||
DuplicatePreimage: AugmentedError<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* Proposal already made
|
* Proposal already made
|
||||||
**/
|
**/
|
||||||
DuplicateProposal: AugmentedError<ApiType>;
|
DuplicateProposal: AugmentedError<ApiType>;
|
||||||
/**
|
|
||||||
* Imminent
|
|
||||||
**/
|
|
||||||
Imminent: AugmentedError<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* The instant referendum origin is currently disallowed.
|
* The instant referendum origin is currently disallowed.
|
||||||
**/
|
**/
|
||||||
@@ -710,10 +692,6 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* The account is not currently delegating.
|
* The account is not currently delegating.
|
||||||
**/
|
**/
|
||||||
NotDelegating: AugmentedError<ApiType>;
|
NotDelegating: AugmentedError<ApiType>;
|
||||||
/**
|
|
||||||
* Not imminent
|
|
||||||
**/
|
|
||||||
NotImminent: AugmentedError<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* Next external proposal not simple majority
|
* Next external proposal not simple majority
|
||||||
**/
|
**/
|
||||||
@@ -722,14 +700,6 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* The given account did not vote on the referendum.
|
* The given account did not vote on the referendum.
|
||||||
**/
|
**/
|
||||||
NotVoter: AugmentedError<ApiType>;
|
NotVoter: AugmentedError<ApiType>;
|
||||||
/**
|
|
||||||
* Invalid preimage
|
|
||||||
**/
|
|
||||||
PreimageInvalid: AugmentedError<ApiType>;
|
|
||||||
/**
|
|
||||||
* Preimage not found
|
|
||||||
**/
|
|
||||||
PreimageMissing: AugmentedError<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* Proposal still blacklisted
|
* Proposal still blacklisted
|
||||||
**/
|
**/
|
||||||
@@ -743,13 +713,9 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
ReferendumInvalid: AugmentedError<ApiType>;
|
ReferendumInvalid: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Too early
|
* Maximum number of items reached.
|
||||||
**/
|
**/
|
||||||
TooEarly: AugmentedError<ApiType>;
|
TooMany: AugmentedError<ApiType>;
|
||||||
/**
|
|
||||||
* Maximum number of proposals reached.
|
|
||||||
**/
|
|
||||||
TooManyProposals: AugmentedError<ApiType>;
|
|
||||||
/**
|
/**
|
||||||
* Value too low
|
* Value too low
|
||||||
**/
|
**/
|
||||||
@@ -900,6 +866,38 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedError<ApiType>;
|
[key: string]: AugmentedError<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* The provided un-staker is already in Head, and cannot deregister.
|
||||||
|
**/
|
||||||
|
AlreadyHead: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has already been queued.
|
||||||
|
**/
|
||||||
|
AlreadyQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The call is not allowed at this point because the pallet is not active.
|
||||||
|
**/
|
||||||
|
CallNotAllowed: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided Controller account was not found.
|
||||||
|
*
|
||||||
|
* This means that the given account is not bonded.
|
||||||
|
**/
|
||||||
|
NotController: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The bonded account has active unlocking chunks.
|
||||||
|
**/
|
||||||
|
NotFullyBonded: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* The provided un-staker is not in the `Queue`.
|
||||||
|
**/
|
||||||
|
NotQueued: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Generic error
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedError<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* The amount of the bid is less than the minimum allowed.
|
* The amount of the bid is less than the minimum allowed.
|
||||||
@@ -1307,7 +1305,7 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
/**
|
/**
|
||||||
* Preimage is too large to store on-chain.
|
* Preimage is too large to store on-chain.
|
||||||
**/
|
**/
|
||||||
TooLarge: AugmentedError<ApiType>;
|
TooBig: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Generic error
|
* Generic error
|
||||||
**/
|
**/
|
||||||
@@ -1582,6 +1580,10 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* Failed to schedule a call
|
* Failed to schedule a call
|
||||||
**/
|
**/
|
||||||
FailedToSchedule: AugmentedError<ApiType>;
|
FailedToSchedule: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Attempt to use a non-named function on a named task.
|
||||||
|
**/
|
||||||
|
Named: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* Cannot find the scheduled call.
|
* Cannot find the scheduled call.
|
||||||
**/
|
**/
|
||||||
@@ -1724,6 +1726,10 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
* A nomination target was supplied that was blocked or otherwise not a validator.
|
* A nomination target was supplied that was blocked or otherwise not a validator.
|
||||||
**/
|
**/
|
||||||
BadTarget: AugmentedError<ApiType>;
|
BadTarget: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Some bound is not met.
|
||||||
|
**/
|
||||||
|
BoundNotMet: AugmentedError<ApiType>;
|
||||||
/**
|
/**
|
||||||
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
* The user has enough bond and thus cannot be chilled forcefully by an external person.
|
||||||
**/
|
**/
|
||||||
@@ -2183,6 +2189,16 @@ declare module '@polkadot/api-base/types/errors' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedError<ApiType>;
|
[key: string]: AugmentedError<ApiType>;
|
||||||
};
|
};
|
||||||
|
voterList: {
|
||||||
|
/**
|
||||||
|
* A error in the list interface implementation.
|
||||||
|
**/
|
||||||
|
List: AugmentedError<ApiType>;
|
||||||
|
/**
|
||||||
|
* Generic error
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedError<ApiType>;
|
||||||
|
};
|
||||||
whitelist: {
|
whitelist: {
|
||||||
/**
|
/**
|
||||||
* The call was already whitelisted; No-Op.
|
* The call was already whitelisted; No-Op.
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import type { ApiTypes, AugmentedEvent } from '@polkadot/api-base/types';
|
|||||||
import type { Bytes, Null, Option, Result, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
import type { Bytes, Null, Option, Result, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
||||||
import type { ITuple } from '@polkadot/types-codec/types';
|
import type { ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { AccountId32, H256 } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId32, H256 } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportDispatchDispatchInfo, FrameSupportDispatchPostDispatchInfo, FrameSupportScheduleLookupError, FrameSupportTokensMiscBalanceStatus, KitchensinkRuntimeProxyType, PalletAllianceCid, PalletAllianceUnscrupulousItem, PalletConvictionVotingTally, PalletDemocracyVoteAccountVote, PalletDemocracyVoteThreshold, PalletElectionProviderMultiPhaseElectionCompute, PalletImOnlineSr25519AppSr25519Public, PalletMultisigTimepoint, PalletNominationPoolsPoolState, PalletRankedCollectiveTally, PalletRankedCollectiveVoteRecord, PalletStakingExposure, PalletStakingValidatorPrefs, PalletStateTrieMigrationError, PalletStateTrieMigrationMigrationCompute, SpFinalityGrandpaAppPublic, SpNposElectionsElectionScore, SpRuntimeDispatchError, SpRuntimeDispatchErrorWithPostInfo } from '@polkadot/types/lookup';
|
import type { FrameSupportDispatchDispatchInfo, FrameSupportDispatchPostDispatchInfo, FrameSupportPreimagesBounded, FrameSupportTokensMiscBalanceStatus, KitchensinkRuntimeProxyType, PalletAllianceCid, PalletAllianceUnscrupulousItem, PalletConvictionVotingTally, PalletDemocracyVoteAccountVote, PalletDemocracyVoteThreshold, PalletElectionProviderMultiPhaseElectionCompute, PalletImOnlineSr25519AppSr25519Public, PalletMultisigTimepoint, PalletNominationPoolsPoolState, PalletRankedCollectiveTally, PalletRankedCollectiveVoteRecord, PalletStakingExposure, PalletStakingValidatorPrefs, PalletStateTrieMigrationError, PalletStateTrieMigrationMigrationCompute, SpFinalityGrandpaAppPublic, SpNposElectionsElectionScore, SpRuntimeDispatchError, SpRuntimeDispatchErrorWithPostInfo } from '@polkadot/types/lookup';
|
||||||
|
|
||||||
export type __AugmentedEvent<ApiType extends ApiTypes> = AugmentedEvent<ApiType>;
|
export type __AugmentedEvent<ApiType extends ApiTypes> = AugmentedEvent<ApiType>;
|
||||||
|
|
||||||
@@ -195,20 +195,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
};
|
};
|
||||||
bagsList: {
|
|
||||||
/**
|
|
||||||
* Moved an account from one bag to another.
|
|
||||||
**/
|
|
||||||
Rebagged: AugmentedEvent<ApiType, [who: AccountId32, from: u64, to: u64], { who: AccountId32, from: u64, to: u64 }>;
|
|
||||||
/**
|
|
||||||
* Updated the score of some account to the given amount.
|
|
||||||
**/
|
|
||||||
ScoreUpdated: AugmentedEvent<ApiType, [who: AccountId32, newScore: u64], { who: AccountId32, newScore: u64 }>;
|
|
||||||
/**
|
|
||||||
* Generic event
|
|
||||||
**/
|
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
|
||||||
};
|
|
||||||
balances: {
|
balances: {
|
||||||
/**
|
/**
|
||||||
* A balance was set by root.
|
* A balance was set by root.
|
||||||
@@ -431,10 +417,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* An account has delegated their vote to another account.
|
* An account has delegated their vote to another account.
|
||||||
**/
|
**/
|
||||||
Delegated: AugmentedEvent<ApiType, [who: AccountId32, target: AccountId32], { who: AccountId32, target: AccountId32 }>;
|
Delegated: AugmentedEvent<ApiType, [who: AccountId32, target: AccountId32], { who: AccountId32, target: AccountId32 }>;
|
||||||
/**
|
|
||||||
* A proposal has been enacted.
|
|
||||||
**/
|
|
||||||
Executed: AugmentedEvent<ApiType, [refIndex: u32, result: Result<Null, SpRuntimeDispatchError>], { refIndex: u32, result: Result<Null, SpRuntimeDispatchError> }>;
|
|
||||||
/**
|
/**
|
||||||
* An external proposal has been tabled.
|
* An external proposal has been tabled.
|
||||||
**/
|
**/
|
||||||
@@ -447,26 +429,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* A proposal has been approved by referendum.
|
* A proposal has been approved by referendum.
|
||||||
**/
|
**/
|
||||||
Passed: AugmentedEvent<ApiType, [refIndex: u32], { refIndex: u32 }>;
|
Passed: AugmentedEvent<ApiType, [refIndex: u32], { refIndex: u32 }>;
|
||||||
/**
|
|
||||||
* A proposal could not be executed because its preimage was invalid.
|
|
||||||
**/
|
|
||||||
PreimageInvalid: AugmentedEvent<ApiType, [proposalHash: H256, refIndex: u32], { proposalHash: H256, refIndex: u32 }>;
|
|
||||||
/**
|
|
||||||
* A proposal could not be executed because its preimage was missing.
|
|
||||||
**/
|
|
||||||
PreimageMissing: AugmentedEvent<ApiType, [proposalHash: H256, refIndex: u32], { proposalHash: H256, refIndex: u32 }>;
|
|
||||||
/**
|
|
||||||
* A proposal's preimage was noted, and the deposit taken.
|
|
||||||
**/
|
|
||||||
PreimageNoted: AugmentedEvent<ApiType, [proposalHash: H256, who: AccountId32, deposit: u128], { proposalHash: H256, who: AccountId32, deposit: u128 }>;
|
|
||||||
/**
|
|
||||||
* A registered preimage was removed and the deposit collected by the reaper.
|
|
||||||
**/
|
|
||||||
PreimageReaped: AugmentedEvent<ApiType, [proposalHash: H256, provider: AccountId32, deposit: u128, reaper: AccountId32], { proposalHash: H256, provider: AccountId32, deposit: u128, reaper: AccountId32 }>;
|
|
||||||
/**
|
|
||||||
* A proposal preimage was removed and used (the deposit was returned).
|
|
||||||
**/
|
|
||||||
PreimageUsed: AugmentedEvent<ApiType, [proposalHash: H256, provider: AccountId32, deposit: u128], { proposalHash: H256, provider: AccountId32, deposit: u128 }>;
|
|
||||||
/**
|
/**
|
||||||
* A proposal got canceled.
|
* A proposal got canceled.
|
||||||
**/
|
**/
|
||||||
@@ -486,7 +448,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* A public proposal has been tabled for referendum vote.
|
* A public proposal has been tabled for referendum vote.
|
||||||
**/
|
**/
|
||||||
Tabled: AugmentedEvent<ApiType, [proposalIndex: u32, deposit: u128, depositors: Vec<AccountId32>], { proposalIndex: u32, deposit: u128, depositors: Vec<AccountId32> }>;
|
Tabled: AugmentedEvent<ApiType, [proposalIndex: u32, deposit: u128], { proposalIndex: u32, deposit: u128 }>;
|
||||||
/**
|
/**
|
||||||
* An account has cancelled a previous delegation operation.
|
* An account has cancelled a previous delegation operation.
|
||||||
**/
|
**/
|
||||||
@@ -588,6 +550,33 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* A staker was partially checked for the given eras, but the process did not finish.
|
||||||
|
**/
|
||||||
|
Checking: AugmentedEvent<ApiType, [stash: AccountId32, eras: Vec<u32>], { stash: AccountId32, eras: Vec<u32> }>;
|
||||||
|
/**
|
||||||
|
* Some internal error happened while migrating stash. They are removed as head as a
|
||||||
|
* consequence.
|
||||||
|
**/
|
||||||
|
Errored: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
|
/**
|
||||||
|
* An internal error happened. Operations will be paused now.
|
||||||
|
**/
|
||||||
|
InternalError: AugmentedEvent<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* A staker was slashed for requesting fast-unstake whilst being exposed.
|
||||||
|
**/
|
||||||
|
Slashed: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
|
/**
|
||||||
|
* A staker was unstaked.
|
||||||
|
**/
|
||||||
|
Unstaked: AugmentedEvent<ApiType, [stash: AccountId32, result: Result<Null, SpRuntimeDispatchError>], { stash: AccountId32, result: Result<Null, SpRuntimeDispatchError> }>;
|
||||||
|
/**
|
||||||
|
* Generic event
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* A bid was successfully placed.
|
* A bid was successfully placed.
|
||||||
@@ -858,11 +847,6 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* An announcement was placed to make a call in the future.
|
* An announcement was placed to make a call in the future.
|
||||||
**/
|
**/
|
||||||
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
Announced: AugmentedEvent<ApiType, [real: AccountId32, proxy: AccountId32, callHash: H256], { real: AccountId32, proxy: AccountId32, callHash: H256 }>;
|
||||||
/**
|
|
||||||
* Anonymous account has been created by new proxy with given
|
|
||||||
* disambiguation index and proxy type.
|
|
||||||
**/
|
|
||||||
AnonymousCreated: AugmentedEvent<ApiType, [anonymous: AccountId32, who: AccountId32, proxyType: KitchensinkRuntimeProxyType, disambiguationIndex: u16], { anonymous: AccountId32, who: AccountId32, proxyType: KitchensinkRuntimeProxyType, disambiguationIndex: u16 }>;
|
|
||||||
/**
|
/**
|
||||||
* A proxy was added.
|
* A proxy was added.
|
||||||
**/
|
**/
|
||||||
@@ -875,6 +859,11 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* A proxy was removed.
|
* A proxy was removed.
|
||||||
**/
|
**/
|
||||||
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: KitchensinkRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: KitchensinkRuntimeProxyType, delay: u32 }>;
|
ProxyRemoved: AugmentedEvent<ApiType, [delegator: AccountId32, delegatee: AccountId32, proxyType: KitchensinkRuntimeProxyType, delay: u32], { delegator: AccountId32, delegatee: AccountId32, proxyType: KitchensinkRuntimeProxyType, delay: u32 }>;
|
||||||
|
/**
|
||||||
|
* A pure account has been created by new proxy with given
|
||||||
|
* disambiguation index and proxy type.
|
||||||
|
**/
|
||||||
|
PureCreated: AugmentedEvent<ApiType, [pure: AccountId32, who: AccountId32, proxyType: KitchensinkRuntimeProxyType, disambiguationIndex: u16], { pure: AccountId32, who: AccountId32, proxyType: KitchensinkRuntimeProxyType, disambiguationIndex: u16 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
@@ -929,7 +918,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* A referendum has moved into the deciding phase.
|
* A referendum has moved into the deciding phase.
|
||||||
**/
|
**/
|
||||||
DecisionStarted: AugmentedEvent<ApiType, [index: u32, track: u16, proposalHash: H256, tally: PalletRankedCollectiveTally], { index: u32, track: u16, proposalHash: H256, tally: PalletRankedCollectiveTally }>;
|
DecisionStarted: AugmentedEvent<ApiType, [index: u32, track: u16, proposal: FrameSupportPreimagesBounded, tally: PalletRankedCollectiveTally], { index: u32, track: u16, proposal: FrameSupportPreimagesBounded, tally: PalletRankedCollectiveTally }>;
|
||||||
/**
|
/**
|
||||||
* A deposit has been slashaed.
|
* A deposit has been slashaed.
|
||||||
**/
|
**/
|
||||||
@@ -945,7 +934,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* A referendum has being submitted.
|
* A referendum has being submitted.
|
||||||
**/
|
**/
|
||||||
Submitted: AugmentedEvent<ApiType, [index: u32, track: u16, proposalHash: H256], { index: u32, track: u16, proposalHash: H256 }>;
|
Submitted: AugmentedEvent<ApiType, [index: u32, track: u16, proposal: FrameSupportPreimagesBounded], { index: u32, track: u16, proposal: FrameSupportPreimagesBounded }>;
|
||||||
/**
|
/**
|
||||||
* A referendum has been timed out without being decided.
|
* A referendum has been timed out without being decided.
|
||||||
**/
|
**/
|
||||||
@@ -1011,7 +1000,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* A referendum has moved into the deciding phase.
|
* A referendum has moved into the deciding phase.
|
||||||
**/
|
**/
|
||||||
DecisionStarted: AugmentedEvent<ApiType, [index: u32, track: u16, proposalHash: H256, tally: PalletConvictionVotingTally], { index: u32, track: u16, proposalHash: H256, tally: PalletConvictionVotingTally }>;
|
DecisionStarted: AugmentedEvent<ApiType, [index: u32, track: u16, proposal: FrameSupportPreimagesBounded, tally: PalletConvictionVotingTally], { index: u32, track: u16, proposal: FrameSupportPreimagesBounded, tally: PalletConvictionVotingTally }>;
|
||||||
/**
|
/**
|
||||||
* A deposit has been slashaed.
|
* A deposit has been slashaed.
|
||||||
**/
|
**/
|
||||||
@@ -1027,7 +1016,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* A referendum has being submitted.
|
* A referendum has being submitted.
|
||||||
**/
|
**/
|
||||||
Submitted: AugmentedEvent<ApiType, [index: u32, track: u16, proposalHash: H256], { index: u32, track: u16, proposalHash: H256 }>;
|
Submitted: AugmentedEvent<ApiType, [index: u32, track: u16, proposal: FrameSupportPreimagesBounded], { index: u32, track: u16, proposal: FrameSupportPreimagesBounded }>;
|
||||||
/**
|
/**
|
||||||
* A referendum has been timed out without being decided.
|
* A referendum has been timed out without being decided.
|
||||||
**/
|
**/
|
||||||
@@ -1051,7 +1040,7 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* The call for the provided hash was not found so the task has been aborted.
|
* The call for the provided hash was not found so the task has been aborted.
|
||||||
**/
|
**/
|
||||||
CallLookupFailed: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<Bytes>, error: FrameSupportScheduleLookupError], { task: ITuple<[u32, u32]>, id: Option<Bytes>, error: FrameSupportScheduleLookupError }>;
|
CallUnavailable: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<U8aFixed>], { task: ITuple<[u32, u32]>, id: Option<U8aFixed> }>;
|
||||||
/**
|
/**
|
||||||
* Canceled some task.
|
* Canceled some task.
|
||||||
**/
|
**/
|
||||||
@@ -1059,7 +1048,15 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
/**
|
/**
|
||||||
* Dispatched some task.
|
* Dispatched some task.
|
||||||
**/
|
**/
|
||||||
Dispatched: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<Bytes>, result: Result<Null, SpRuntimeDispatchError>], { task: ITuple<[u32, u32]>, id: Option<Bytes>, result: Result<Null, SpRuntimeDispatchError> }>;
|
Dispatched: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<U8aFixed>, result: Result<Null, SpRuntimeDispatchError>], { task: ITuple<[u32, u32]>, id: Option<U8aFixed>, result: Result<Null, SpRuntimeDispatchError> }>;
|
||||||
|
/**
|
||||||
|
* The given task was unable to be renewed since the agenda is full at that block.
|
||||||
|
**/
|
||||||
|
PeriodicFailed: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<U8aFixed>], { task: ITuple<[u32, u32]>, id: Option<U8aFixed> }>;
|
||||||
|
/**
|
||||||
|
* The given task can never be executed since it is overweight.
|
||||||
|
**/
|
||||||
|
PermanentlyOverweight: AugmentedEvent<ApiType, [task: ITuple<[u32, u32]>, id: Option<U8aFixed>], { task: ITuple<[u32, u32]>, id: Option<U8aFixed> }>;
|
||||||
/**
|
/**
|
||||||
* Scheduled some task.
|
* Scheduled some task.
|
||||||
**/
|
**/
|
||||||
@@ -1160,40 +1157,37 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
* NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,
|
||||||
* it will not be emitted for staking rewards when they are added to stake.
|
* it will not be emitted for staking rewards when they are added to stake.
|
||||||
**/
|
**/
|
||||||
Bonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Bonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* An account has stopped participating as either a validator or nominator.
|
* An account has stopped participating as either a validator or nominator.
|
||||||
* \[stash\]
|
|
||||||
**/
|
**/
|
||||||
Chilled: AugmentedEvent<ApiType, [AccountId32]>;
|
Chilled: AugmentedEvent<ApiType, [stash: AccountId32], { stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The era payout has been set; the first balance is the validator-payout; the second is
|
* The era payout has been set; the first balance is the validator-payout; the second is
|
||||||
* the remainder from the maximum amount of reward.
|
* the remainder from the maximum amount of reward.
|
||||||
* \[era_index, validator_payout, remainder\]
|
|
||||||
**/
|
**/
|
||||||
EraPaid: AugmentedEvent<ApiType, [u32, u128, u128]>;
|
EraPaid: AugmentedEvent<ApiType, [eraIndex: u32, validatorPayout: u128, remainder: u128], { eraIndex: u32, validatorPayout: u128, remainder: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A nominator has been kicked from a validator. \[nominator, stash\]
|
* A nominator has been kicked from a validator.
|
||||||
**/
|
**/
|
||||||
Kicked: AugmentedEvent<ApiType, [AccountId32, AccountId32]>;
|
Kicked: AugmentedEvent<ApiType, [nominator: AccountId32, stash: AccountId32], { nominator: AccountId32, stash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* An old slashing report from a prior era was discarded because it could
|
* An old slashing report from a prior era was discarded because it could
|
||||||
* not be processed. \[session_index\]
|
* not be processed.
|
||||||
**/
|
**/
|
||||||
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [u32]>;
|
OldSlashingReportDiscarded: AugmentedEvent<ApiType, [sessionIndex: u32], { sessionIndex: u32 }>;
|
||||||
/**
|
/**
|
||||||
* The stakers' rewards are getting paid. \[era_index, validator_stash\]
|
* The stakers' rewards are getting paid.
|
||||||
**/
|
**/
|
||||||
PayoutStarted: AugmentedEvent<ApiType, [u32, AccountId32]>;
|
PayoutStarted: AugmentedEvent<ApiType, [eraIndex: u32, validatorStash: AccountId32], { eraIndex: u32, validatorStash: AccountId32 }>;
|
||||||
/**
|
/**
|
||||||
* The nominator has been rewarded by this amount. \[stash, amount\]
|
* The nominator has been rewarded by this amount.
|
||||||
**/
|
**/
|
||||||
Rewarded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Rewarded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* One validator (and its nominators) has been slashed by the given amount.
|
* One staker (and potentially its nominators) has been slashed by the given amount.
|
||||||
* \[validator, amount\]
|
|
||||||
**/
|
**/
|
||||||
Slashed: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Slashed: AugmentedEvent<ApiType, [staker: AccountId32, amount: u128], { staker: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A new set of stakers was elected.
|
* A new set of stakers was elected.
|
||||||
**/
|
**/
|
||||||
@@ -1203,18 +1197,18 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
StakingElectionFailed: AugmentedEvent<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* An account has unbonded this amount. \[stash, amount\]
|
* An account has unbonded this amount.
|
||||||
**/
|
**/
|
||||||
Unbonded: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Unbonded: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* A validator has set their preferences.
|
* A validator has set their preferences.
|
||||||
**/
|
**/
|
||||||
ValidatorPrefsSet: AugmentedEvent<ApiType, [AccountId32, PalletStakingValidatorPrefs]>;
|
ValidatorPrefsSet: AugmentedEvent<ApiType, [stash: AccountId32, prefs: PalletStakingValidatorPrefs], { stash: AccountId32, prefs: PalletStakingValidatorPrefs }>;
|
||||||
/**
|
/**
|
||||||
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
* An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`
|
||||||
* from the unlocking queue. \[stash, amount\]
|
* from the unlocking queue.
|
||||||
**/
|
**/
|
||||||
Withdrawn: AugmentedEvent<ApiType, [AccountId32, u128]>;
|
Withdrawn: AugmentedEvent<ApiType, [stash: AccountId32, amount: u128], { stash: AccountId32, amount: u128 }>;
|
||||||
/**
|
/**
|
||||||
* Generic event
|
* Generic event
|
||||||
**/
|
**/
|
||||||
@@ -1612,6 +1606,20 @@ declare module '@polkadot/api-base/types/events' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: AugmentedEvent<ApiType>;
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
};
|
};
|
||||||
|
voterList: {
|
||||||
|
/**
|
||||||
|
* Moved an account from one bag to another.
|
||||||
|
**/
|
||||||
|
Rebagged: AugmentedEvent<ApiType, [who: AccountId32, from: u64, to: u64], { who: AccountId32, from: u64, to: u64 }>;
|
||||||
|
/**
|
||||||
|
* Updated the score of some account to the given amount.
|
||||||
|
**/
|
||||||
|
ScoreUpdated: AugmentedEvent<ApiType, [who: AccountId32, newScore: u64], { who: AccountId32, newScore: u64 }>;
|
||||||
|
/**
|
||||||
|
* Generic event
|
||||||
|
**/
|
||||||
|
[key: string]: AugmentedEvent<ApiType>;
|
||||||
|
};
|
||||||
whitelist: {
|
whitelist: {
|
||||||
CallWhitelisted: AugmentedEvent<ApiType, [callHash: H256], { callHash: H256 }>;
|
CallWhitelisted: AugmentedEvent<ApiType, [callHash: H256], { callHash: H256 }>;
|
||||||
WhitelistedCallDispatched: AugmentedEvent<ApiType, [callHash: H256, result: Result<FrameSupportDispatchPostDispatchInfo, SpRuntimeDispatchErrorWithPostInfo>], { callHash: H256, result: Result<FrameSupportDispatchPostDispatchInfo, SpRuntimeDispatchErrorWithPostInfo> }>;
|
WhitelistedCallDispatched: AugmentedEvent<ApiType, [callHash: H256, result: Result<FrameSupportDispatchPostDispatchInfo, SpRuntimeDispatchErrorWithPostInfo>], { callHash: H256, result: Result<FrameSupportDispatchPostDispatchInfo, SpRuntimeDispatchErrorWithPostInfo> }>;
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ import '@polkadot/api-base/types/storage';
|
|||||||
|
|
||||||
import type { ApiTypes, AugmentedQuery, QueryableStorageEntry } from '@polkadot/api-base/types';
|
import type { ApiTypes, AugmentedQuery, QueryableStorageEntry } from '@polkadot/api-base/types';
|
||||||
import type { Data } from '@polkadot/types';
|
import type { Data } from '@polkadot/types';
|
||||||
import type { BTreeMap, Bytes, Null, Option, U8aFixed, Vec, WrapperKeepOpaque, WrapperOpaque, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
import type { BTreeMap, Bytes, Null, Option, U8aFixed, Vec, WrapperOpaque, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
||||||
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId32, Call, H256, Perbill, Percent } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceMemberRole, PalletAssetsApproval, PalletAssetsAssetAccount, PalletAssetsAssetDetails, PalletAssetsAssetMetadata, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletContractsStorageDeletedContract, PalletContractsStorageRawContractInfo, PalletContractsWasmOwnerInfo, PalletContractsWasmPrefabWasmModule, PalletConvictionVotingVoteVoting, PalletDemocracyPreimageStatus, PalletDemocracyReferendumInfo, PalletDemocracyReleases, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletGiltActiveGilt, PalletGiltActiveGiltsTotal, PalletGiltGiltBid, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletLotteryLotteryConfig, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletRankedCollectiveMemberRecord, PalletRankedCollectiveVoteRecord, PalletRecoveryActiveRecovery, PalletRecoveryRecoveryConfig, PalletReferendaReferendumInfoConvictionVotingTally, PalletReferendaReferendumInfoRankedCollectiveTally, PalletSchedulerScheduledV3, PalletSocietyBid, PalletSocietyBidKind, PalletSocietyVote, PalletSocietyVouchingStatus, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTransactionStorageTransactionInfo, PalletTreasuryProposal, PalletUniquesCollectionDetails, PalletUniquesCollectionMetadata, PalletUniquesItemDetails, PalletUniquesItemMetadata, PalletVestingReleases, PalletVestingVestingInfo, SpAuthorityDiscoveryAppPublic, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails } from '@polkadot/types/lookup';
|
import type { FrameSupportDispatchPerDispatchClassWeight, FrameSupportPreimagesBounded, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceMemberRole, PalletAssetsApproval, PalletAssetsAssetAccount, PalletAssetsAssetDetails, PalletAssetsAssetMetadata, PalletAuthorshipUncleEntryItem, PalletBagsListListBag, PalletBagsListListNode, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletBountiesBounty, PalletChildBountiesChildBounty, PalletCollectiveVotes, PalletContractsStorageContractInfo, PalletContractsStorageDeletedContract, PalletContractsWasmOwnerInfo, PalletContractsWasmPrefabWasmModule, PalletConvictionVotingVoteVoting, PalletDemocracyReferendumInfo, PalletDemocracyVoteThreshold, PalletDemocracyVoteVoting, PalletElectionProviderMultiPhasePhase, PalletElectionProviderMultiPhaseReadySolution, PalletElectionProviderMultiPhaseRoundSnapshot, PalletElectionProviderMultiPhaseSignedSignedSubmission, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenSeatHolder, PalletElectionsPhragmenVoter, PalletFastUnstakeUnstakeRequest, PalletGiltActiveGilt, PalletGiltActiveGiltsTotal, PalletGiltGiltBid, PalletGrandpaStoredPendingChange, PalletGrandpaStoredState, PalletIdentityRegistrarInfo, PalletIdentityRegistration, PalletImOnlineBoundedOpaqueNetworkState, PalletImOnlineSr25519AppSr25519Public, PalletLotteryLotteryConfig, PalletMultisigMultisig, PalletNominationPoolsBondedPoolInner, PalletNominationPoolsPoolMember, PalletNominationPoolsRewardPool, PalletNominationPoolsSubPools, PalletPreimageRequestStatus, PalletProxyAnnouncement, PalletProxyProxyDefinition, PalletRankedCollectiveMemberRecord, PalletRankedCollectiveVoteRecord, PalletRecoveryActiveRecovery, PalletRecoveryRecoveryConfig, PalletReferendaReferendumInfoConvictionVotingTally, PalletReferendaReferendumInfoRankedCollectiveTally, PalletSchedulerScheduled, PalletSocietyBid, PalletSocietyBidKind, PalletSocietyVote, PalletSocietyVouchingStatus, PalletStakingActiveEraInfo, PalletStakingEraRewardPoints, PalletStakingExposure, PalletStakingForcing, PalletStakingNominations, PalletStakingReleases, PalletStakingRewardDestination, PalletStakingSlashingSlashingSpans, PalletStakingSlashingSpanRecord, PalletStakingStakingLedger, PalletStakingUnappliedSlash, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletTipsOpenTip, PalletTransactionPaymentReleases, PalletTransactionStorageTransactionInfo, PalletTreasuryProposal, PalletUniquesCollectionDetails, PalletUniquesCollectionMetadata, PalletUniquesItemDetails, PalletUniquesItemMetadata, PalletVestingReleases, PalletVestingVestingInfo, SpAuthorityDiscoveryAppPublic, SpConsensusBabeAppPublic, SpConsensusBabeBabeEpochConfiguration, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBabeDigestsPreDigest, SpCoreCryptoKeyTypeId, SpNposElectionsElectionScore, SpRuntimeDigest, SpStakingOffenceOffenceDetails } from '@polkadot/types/lookup';
|
||||||
import type { Observable } from '@polkadot/types/types';
|
import type { Observable } from '@polkadot/types/types';
|
||||||
|
|
||||||
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
export type __AugmentedQuery<ApiType extends ApiTypes> = AugmentedQuery<ApiType, () => unknown>;
|
||||||
@@ -245,28 +245,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
bagsList: {
|
|
||||||
/**
|
|
||||||
* Counter for the related counted storage map
|
|
||||||
**/
|
|
||||||
counterForListNodes: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
|
||||||
/**
|
|
||||||
* A bag stored in storage.
|
|
||||||
*
|
|
||||||
* Stores a `Bag` struct, which stores head and tail pointers to itself.
|
|
||||||
**/
|
|
||||||
listBags: AugmentedQuery<ApiType, (arg: u64 | AnyNumber | Uint8Array) => Observable<Option<PalletBagsListListBag>>, [u64]> & QueryableStorageEntry<ApiType, [u64]>;
|
|
||||||
/**
|
|
||||||
* A single node, within some bag.
|
|
||||||
*
|
|
||||||
* Nodes store links forward and back within their respective bags.
|
|
||||||
**/
|
|
||||||
listNodes: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<PalletBagsListListNode>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
|
||||||
/**
|
|
||||||
* Generic query
|
|
||||||
**/
|
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
|
||||||
};
|
|
||||||
balances: {
|
balances: {
|
||||||
/**
|
/**
|
||||||
* The Balances pallet example of storing the balance of an account.
|
* The Balances pallet example of storing the balance of an account.
|
||||||
@@ -378,7 +356,7 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
*
|
*
|
||||||
* TWOX-NOTE: SAFE since `AccountId` is a secure hash.
|
* TWOX-NOTE: SAFE since `AccountId` is a secure hash.
|
||||||
**/
|
**/
|
||||||
contractInfoOf: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<PalletContractsStorageRawContractInfo>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
contractInfoOf: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<PalletContractsStorageContractInfo>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
||||||
/**
|
/**
|
||||||
* Evicted contracts that await child trie deletion.
|
* Evicted contracts that await child trie deletion.
|
||||||
*
|
*
|
||||||
@@ -503,20 +481,15 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
* - `LastTabledWasExternal` is `false`; or
|
* - `LastTabledWasExternal` is `false`; or
|
||||||
* - `PublicProps` is empty.
|
* - `PublicProps` is empty.
|
||||||
**/
|
**/
|
||||||
nextExternal: AugmentedQuery<ApiType, () => Observable<Option<ITuple<[H256, PalletDemocracyVoteThreshold]>>>, []> & QueryableStorageEntry<ApiType, []>;
|
nextExternal: AugmentedQuery<ApiType, () => Observable<Option<ITuple<[FrameSupportPreimagesBounded, PalletDemocracyVoteThreshold]>>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
|
||||||
* Map of hashes to the proposal preimage, along with who registered it and their deposit.
|
|
||||||
* The block number is the block at which it was deposited.
|
|
||||||
**/
|
|
||||||
preimages: AugmentedQuery<ApiType, (arg: H256 | string | Uint8Array) => Observable<Option<PalletDemocracyPreimageStatus>>, [H256]> & QueryableStorageEntry<ApiType, [H256]>;
|
|
||||||
/**
|
/**
|
||||||
* The number of (public) proposals that have been made so far.
|
* The number of (public) proposals that have been made so far.
|
||||||
**/
|
**/
|
||||||
publicPropCount: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
publicPropCount: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* The public proposals. Unsorted. The second item is the proposal's hash.
|
* The public proposals. Unsorted. The second item is the proposal.
|
||||||
**/
|
**/
|
||||||
publicProps: AugmentedQuery<ApiType, () => Observable<Vec<ITuple<[u32, H256, AccountId32]>>>, []> & QueryableStorageEntry<ApiType, []>;
|
publicProps: AugmentedQuery<ApiType, () => Observable<Vec<ITuple<[u32, FrameSupportPreimagesBounded, AccountId32]>>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* The next free referendum index, aka the number of referenda started so far.
|
* The next free referendum index, aka the number of referenda started so far.
|
||||||
**/
|
**/
|
||||||
@@ -527,12 +500,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
* TWOX-NOTE: SAFE as indexes are not under an attacker’s control.
|
* TWOX-NOTE: SAFE as indexes are not under an attacker’s control.
|
||||||
**/
|
**/
|
||||||
referendumInfoOf: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Option<PalletDemocracyReferendumInfo>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
|
referendumInfoOf: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Option<PalletDemocracyReferendumInfo>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
|
||||||
/**
|
|
||||||
* Storage version of the pallet.
|
|
||||||
*
|
|
||||||
* New networks start with last version.
|
|
||||||
**/
|
|
||||||
storageVersion: AugmentedQuery<ApiType, () => Observable<Option<PalletDemocracyReleases>>, []> & QueryableStorageEntry<ApiType, []>;
|
|
||||||
/**
|
/**
|
||||||
* All votes for a particular voter. We store the balance for the number of votes that we
|
* All votes for a particular voter. We store the balance for the number of votes that we
|
||||||
* have recorded. The second item is the total amount of delegations, that will be added.
|
* have recorded. The second item is the total amount of delegations, that will be added.
|
||||||
@@ -662,6 +629,35 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Counter for the related counted storage map
|
||||||
|
**/
|
||||||
|
counterForQueue: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* Number of eras to check per block.
|
||||||
|
*
|
||||||
|
* If set to 0, this pallet does absolutely nothing.
|
||||||
|
*
|
||||||
|
* Based on the amount of weight available at `on_idle`, up to this many eras of a single
|
||||||
|
* nominator might be checked.
|
||||||
|
**/
|
||||||
|
erasToCheckPerBlock: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The current "head of the queue" being unstaked.
|
||||||
|
**/
|
||||||
|
head: AugmentedQuery<ApiType, () => Observable<Option<PalletFastUnstakeUnstakeRequest>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* The map of all accounts wishing to be unstaked.
|
||||||
|
*
|
||||||
|
* Keeps track of `AccountId` wishing to unstake and it's corresponding deposit.
|
||||||
|
**/
|
||||||
|
queue: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<u128>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
||||||
|
/**
|
||||||
|
* Generic query
|
||||||
|
**/
|
||||||
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* The currently active gilts, indexed according to the order of creation.
|
* The currently active gilts, indexed according to the order of creation.
|
||||||
@@ -851,7 +847,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
multisig: {
|
multisig: {
|
||||||
calls: AugmentedQuery<ApiType, (arg: U8aFixed | string | Uint8Array) => Observable<Option<ITuple<[WrapperKeepOpaque<Call>, AccountId32, u128]>>>, [U8aFixed]> & QueryableStorageEntry<ApiType, [U8aFixed]>;
|
|
||||||
/**
|
/**
|
||||||
* The set of open multisig operations.
|
* The set of open multisig operations.
|
||||||
**/
|
**/
|
||||||
@@ -977,10 +972,7 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
preimage: {
|
preimage: {
|
||||||
/**
|
preimageFor: AugmentedQuery<ApiType, (arg: ITuple<[H256, u32]> | [H256 | string | Uint8Array, u32 | AnyNumber | Uint8Array]) => Observable<Option<Bytes>>, [ITuple<[H256, u32]>]> & QueryableStorageEntry<ApiType, [ITuple<[H256, u32]>]>;
|
||||||
* The preimages stored by this pallet.
|
|
||||||
**/
|
|
||||||
preimageFor: AugmentedQuery<ApiType, (arg: H256 | string | Uint8Array) => Observable<Option<Bytes>>, [H256]> & QueryableStorageEntry<ApiType, [H256]>;
|
|
||||||
/**
|
/**
|
||||||
* The request status of a given hash.
|
* The request status of a given hash.
|
||||||
**/
|
**/
|
||||||
@@ -1123,11 +1115,15 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
/**
|
/**
|
||||||
* Items to be executed, indexed by the block number that they should be executed on.
|
* Items to be executed, indexed by the block number that they should be executed on.
|
||||||
**/
|
**/
|
||||||
agenda: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Vec<Option<PalletSchedulerScheduledV3>>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
|
agenda: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Vec<Option<PalletSchedulerScheduled>>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
|
||||||
|
incompleteSince: AugmentedQuery<ApiType, () => Observable<Option<u32>>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
/**
|
||||||
* Lookup from identity to the block number and index of the task.
|
* Lookup from a name to the block number and index of the task.
|
||||||
|
*
|
||||||
|
* For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4
|
||||||
|
* identities.
|
||||||
**/
|
**/
|
||||||
lookup: AugmentedQuery<ApiType, (arg: Bytes | string | Uint8Array) => Observable<Option<ITuple<[u32, u32]>>>, [Bytes]> & QueryableStorageEntry<ApiType, [Bytes]>;
|
lookup: AugmentedQuery<ApiType, (arg: U8aFixed | string | Uint8Array) => Observable<Option<ITuple<[u32, u32]>>>, [U8aFixed]> & QueryableStorageEntry<ApiType, [U8aFixed]>;
|
||||||
/**
|
/**
|
||||||
* Generic query
|
* Generic query
|
||||||
**/
|
**/
|
||||||
@@ -1353,16 +1349,6 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
* Mode of era forcing.
|
* Mode of era forcing.
|
||||||
**/
|
**/
|
||||||
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
forceEra: AugmentedQuery<ApiType, () => Observable<PalletStakingForcing>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
/**
|
|
||||||
* Number of eras to keep in history.
|
|
||||||
*
|
|
||||||
* Information is kept for eras in `[current_era - history_depth; current_era]`.
|
|
||||||
*
|
|
||||||
* Must be more than the number of eras delayed by session otherwise. I.e. active era must
|
|
||||||
* always be in history. I.e. `active_era > current_era - history_depth` must be
|
|
||||||
* guaranteed.
|
|
||||||
**/
|
|
||||||
historyDepth: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
|
||||||
/**
|
/**
|
||||||
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
* Any validators that may never be slashed or forcibly kicked. It's a Vec since they're
|
||||||
* easy to initialize and the performance hit is minimal (we expect no more than four
|
* easy to initialize and the performance hit is minimal (we expect no more than four
|
||||||
@@ -1804,6 +1790,28 @@ declare module '@polkadot/api-base/types/storage' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: QueryableStorageEntry<ApiType>;
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
};
|
};
|
||||||
|
voterList: {
|
||||||
|
/**
|
||||||
|
* Counter for the related counted storage map
|
||||||
|
**/
|
||||||
|
counterForListNodes: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
|
||||||
|
/**
|
||||||
|
* A bag stored in storage.
|
||||||
|
*
|
||||||
|
* Stores a `Bag` struct, which stores head and tail pointers to itself.
|
||||||
|
**/
|
||||||
|
listBags: AugmentedQuery<ApiType, (arg: u64 | AnyNumber | Uint8Array) => Observable<Option<PalletBagsListListBag>>, [u64]> & QueryableStorageEntry<ApiType, [u64]>;
|
||||||
|
/**
|
||||||
|
* A single node, within some bag.
|
||||||
|
*
|
||||||
|
* Nodes store links forward and back within their respective bags.
|
||||||
|
**/
|
||||||
|
listNodes: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<PalletBagsListListNode>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
|
||||||
|
/**
|
||||||
|
* Generic query
|
||||||
|
**/
|
||||||
|
[key: string]: QueryableStorageEntry<ApiType>;
|
||||||
|
};
|
||||||
whitelist: {
|
whitelist: {
|
||||||
whitelistedCall: AugmentedQuery<ApiType, (arg: H256 | string | Uint8Array) => Observable<Option<Null>>, [H256]> & QueryableStorageEntry<ApiType, [H256]>;
|
whitelistedCall: AugmentedQuery<ApiType, (arg: H256 | string | Uint8Array) => Observable<Option<Null>>, [H256]> & QueryableStorageEntry<ApiType, [H256]>;
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ import type { BabeEquivocationProof, BabeGenesisConfiguration, Epoch, OpaqueKeyO
|
|||||||
import type { CheckInherentsResult, InherentData } from '@polkadot/types/interfaces/blockbuilder';
|
import type { CheckInherentsResult, InherentData } from '@polkadot/types/interfaces/blockbuilder';
|
||||||
import type { BlockHash } from '@polkadot/types/interfaces/chain';
|
import type { BlockHash } from '@polkadot/types/interfaces/chain';
|
||||||
import type { AuthorityId } from '@polkadot/types/interfaces/consensus';
|
import type { AuthorityId } from '@polkadot/types/interfaces/consensus';
|
||||||
import type { CodeUploadResult, ContractExecResult, ContractInstantiateResult } from '@polkadot/types/interfaces/contracts';
|
import type { CodeSource, CodeUploadResult, ContractExecResult, ContractInstantiateResult } from '@polkadot/types/interfaces/contracts';
|
||||||
import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';
|
import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';
|
||||||
import type { AuthorityList, GrandpaEquivocationProof, SetId } from '@polkadot/types/interfaces/grandpa';
|
import type { AuthorityList, GrandpaEquivocationProof, SetId } from '@polkadot/types/interfaces/grandpa';
|
||||||
import type { OpaqueMetadata } from '@polkadot/types/interfaces/metadata';
|
import type { OpaqueMetadata } from '@polkadot/types/interfaces/metadata';
|
||||||
@@ -118,7 +118,7 @@ declare module '@polkadot/api-base/types/calls' {
|
|||||||
/**
|
/**
|
||||||
* Instantiate a new contract.
|
* Instantiate a new contract.
|
||||||
**/
|
**/
|
||||||
instantiate: AugmentedCall<ApiType, (origin: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array, gasLimit: u64 | AnyNumber | Uint8Array, storageDepositLimit: Option<Balance> | null | Uint8Array | Balance | AnyNumber, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => Observable<ContractInstantiateResult>>;
|
instantiate: AugmentedCall<ApiType, (origin: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array, gasLimit: u64 | AnyNumber | Uint8Array, storageDepositLimit: Option<Balance> | null | Uint8Array | Balance | AnyNumber, code: CodeSource | { Upload: any } | { Existing: any } | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => Observable<ContractInstantiateResult>>;
|
||||||
/**
|
/**
|
||||||
* Upload new code without instantiating a contract from it.
|
* Upload new code without instantiating a contract from it.
|
||||||
**/
|
**/
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ import '@polkadot/api-base/types/submittable';
|
|||||||
|
|
||||||
import type { ApiTypes, AugmentedSubmittable, SubmittableExtrinsic, SubmittableExtrinsicFunction } from '@polkadot/api-base/types';
|
import type { ApiTypes, AugmentedSubmittable, SubmittableExtrinsic, SubmittableExtrinsicFunction } from '@polkadot/api-base/types';
|
||||||
import type { Data } from '@polkadot/types';
|
import type { Data } from '@polkadot/types';
|
||||||
import type { Bytes, Compact, Option, U8aFixed, Vec, WrapperKeepOpaque, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
import type { Bytes, Compact, Option, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
||||||
import type { AnyNumber, IMethod, ITuple } from '@polkadot/types-codec/types';
|
import type { AnyNumber, IMethod, ITuple } from '@polkadot/types-codec/types';
|
||||||
import type { AccountId32, Call, H256, MultiAddress, Perbill, Percent, Perquintill, Weight } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId32, Call, H256, MultiAddress, Perbill, Percent, Perquintill } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { FrameSupportScheduleDispatchTime, FrameSupportScheduleMaybeHashed, KitchensinkRuntimeOriginCaller, KitchensinkRuntimeProxyType, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceDisbandWitness, PalletAllianceUnscrupulousItem, PalletAssetsDestroyWitness, PalletConvictionVotingConviction, PalletConvictionVotingVoteAccountVote, PalletDemocracyConviction, PalletDemocracyVoteAccountVote, PalletElectionProviderMultiPhaseRawSolution, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenRenouncing, PalletIdentityBitFlags, PalletIdentityIdentityInfo, PalletIdentityJudgement, PalletImOnlineHeartbeat, PalletImOnlineSr25519AppSr25519Signature, PalletMultisigTimepoint, PalletNominationPoolsBondExtra, PalletNominationPoolsConfigOpAccountId32, PalletNominationPoolsConfigOpU128, PalletNominationPoolsConfigOpU32, PalletNominationPoolsPoolState, PalletSocietyJudgement, PalletStakingPalletConfigOpPerbill, PalletStakingPalletConfigOpPercent, PalletStakingPalletConfigOpU128, PalletStakingPalletConfigOpU32, PalletStakingRewardDestination, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletStateTrieMigrationProgress, PalletUniquesDestroyWitness, PalletVestingVestingInfo, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusSlotsEquivocationProof, SpFinalityGrandpaEquivocationProof, SpNposElectionsElectionScore, SpNposElectionsSupport, SpRuntimeHeader, SpSessionMembershipProof, SpTransactionStorageProofTransactionStorageProof } from '@polkadot/types/lookup';
|
import type { FrameSupportPreimagesBounded, FrameSupportScheduleDispatchTime, KitchensinkRuntimeOriginCaller, KitchensinkRuntimeProxyType, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceDisbandWitness, PalletAllianceUnscrupulousItem, PalletAssetsDestroyWitness, PalletConvictionVotingConviction, PalletConvictionVotingVoteAccountVote, PalletDemocracyConviction, PalletDemocracyVoteAccountVote, PalletElectionProviderMultiPhaseRawSolution, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenRenouncing, PalletIdentityBitFlags, PalletIdentityIdentityInfo, PalletIdentityJudgement, PalletImOnlineHeartbeat, PalletImOnlineSr25519AppSr25519Signature, PalletMultisigTimepoint, PalletNominationPoolsBondExtra, PalletNominationPoolsConfigOpAccountId32, PalletNominationPoolsConfigOpU128, PalletNominationPoolsConfigOpU32, PalletNominationPoolsPoolState, PalletSocietyJudgement, PalletStakingPalletConfigOpPerbill, PalletStakingPalletConfigOpPercent, PalletStakingPalletConfigOpU128, PalletStakingPalletConfigOpU32, PalletStakingRewardDestination, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletStateTrieMigrationProgress, PalletUniquesDestroyWitness, PalletVestingVestingInfo, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusSlotsEquivocationProof, SpFinalityGrandpaEquivocationProof, SpNposElectionsElectionScore, SpNposElectionsSupport, SpRuntimeHeader, SpSessionMembershipProof, SpTransactionStorageProofTransactionStorageProof, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
|
||||||
|
|
||||||
export type __AugmentedSubmittable = AugmentedSubmittable<() => unknown>;
|
export type __AugmentedSubmittable = AugmentedSubmittable<() => unknown>;
|
||||||
export type __SubmittableExtrinsic<ApiType extends ApiTypes> = SubmittableExtrinsic<ApiType>;
|
export type __SubmittableExtrinsic<ApiType extends ApiTypes> = SubmittableExtrinsic<ApiType>;
|
||||||
@@ -32,7 +32,13 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* Requires the sender to be a founder or fellow.
|
* Requires the sender to be a founder or fellow.
|
||||||
**/
|
**/
|
||||||
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<Weight> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<Weight>, Compact<u32>]>;
|
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, SpWeightsWeightV2Weight, Compact<u32>]>;
|
||||||
|
/**
|
||||||
|
* Close a vote that is either approved, disapproved, or whose voting period has ended.
|
||||||
|
*
|
||||||
|
* Requires the sender to be a founder or fellow.
|
||||||
|
**/
|
||||||
|
closeOldWeight: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<u64> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<u64>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Disband the Alliance, remove all active members and unreserve deposits.
|
* Disband the Alliance, remove all active members and unreserve deposits.
|
||||||
*
|
*
|
||||||
@@ -145,7 +151,42 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - up to 3 events
|
* - up to 3 events
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<Weight> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<Weight>, Compact<u32>]>;
|
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, SpWeightsWeightV2Weight, Compact<u32>]>;
|
||||||
|
/**
|
||||||
|
* Close a vote that is either approved, disapproved or whose voting period has ended.
|
||||||
|
*
|
||||||
|
* May be called by any signed account in order to finish voting and close the proposal.
|
||||||
|
*
|
||||||
|
* If called before the end of the voting period it will only close the vote if it is
|
||||||
|
* has enough votes to be approved or disapproved.
|
||||||
|
*
|
||||||
|
* If called after the end of the voting period abstentions are counted as rejections
|
||||||
|
* unless there is a prime member set and the prime member cast an approval.
|
||||||
|
*
|
||||||
|
* If the close operation completes successfully with disapproval, the transaction fee will
|
||||||
|
* be waived. Otherwise execution of the approved operation will be charged to the caller.
|
||||||
|
*
|
||||||
|
* + `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed
|
||||||
|
* proposal.
|
||||||
|
* + `length_bound`: The upper bound for the length of the proposal in storage. Checked via
|
||||||
|
* `storage::read` so it is `size_of::<u32>() == 4` larger than the pure length.
|
||||||
|
*
|
||||||
|
* # <weight>
|
||||||
|
* ## Weight
|
||||||
|
* - `O(B + M + P1 + P2)` where:
|
||||||
|
* - `B` is `proposal` size in bytes (length-fee-bounded)
|
||||||
|
* - `M` is members-count (code- and governance-bounded)
|
||||||
|
* - `P1` is the complexity of `proposal` preimage.
|
||||||
|
* - `P2` is proposal-count (code-bounded)
|
||||||
|
* - DB:
|
||||||
|
* - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)
|
||||||
|
* - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec
|
||||||
|
* `O(P2)`)
|
||||||
|
* - any mutations done while executing `proposal` (`P1`)
|
||||||
|
* - up to 3 events
|
||||||
|
* # </weight>
|
||||||
|
**/
|
||||||
|
closeOldWeight: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<u64> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<u64>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
||||||
* state.
|
* state.
|
||||||
@@ -740,36 +781,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
};
|
};
|
||||||
bagsList: {
|
|
||||||
/**
|
|
||||||
* Move the caller's Id directly in front of `lighter`.
|
|
||||||
*
|
|
||||||
* The dispatch origin for this call must be _Signed_ and can only be called by the Id of
|
|
||||||
* the account going in front of `lighter`.
|
|
||||||
*
|
|
||||||
* Only works if
|
|
||||||
* - both nodes are within the same bag,
|
|
||||||
* - and `origin` has a greater `Score` than `lighter`.
|
|
||||||
**/
|
|
||||||
putInFrontOf: AugmentedSubmittable<(lighter: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
|
||||||
/**
|
|
||||||
* Declare that some `dislocated` account has, through rewards or penalties, sufficiently
|
|
||||||
* changed its score that it should properly fall into a different bag than its current
|
|
||||||
* one.
|
|
||||||
*
|
|
||||||
* Anyone can call this function about any potentially dislocated account.
|
|
||||||
*
|
|
||||||
* Will always update the stored score of `dislocated` to the correct score, based on
|
|
||||||
* `ScoreProvider`.
|
|
||||||
*
|
|
||||||
* If `dislocated` does not exists, it returns an error.
|
|
||||||
**/
|
|
||||||
rebag: AugmentedSubmittable<(dislocated: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
|
||||||
/**
|
|
||||||
* Generic tx
|
|
||||||
**/
|
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
|
||||||
};
|
|
||||||
balances: {
|
balances: {
|
||||||
/**
|
/**
|
||||||
* Exactly as `transfer`, except the origin must be root and the source account may be
|
* Exactly as `transfer`, except the origin must be root and the source account may be
|
||||||
@@ -1173,7 +1184,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* * If no account exists and the call value is not less than `existential_deposit`,
|
* * If no account exists and the call value is not less than `existential_deposit`,
|
||||||
* a regular account will be created and any value will be transferred.
|
* a regular account will be created and any value will be transferred.
|
||||||
**/
|
**/
|
||||||
call: AugmentedSubmittable<(dest: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<Weight> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Compact<u128>, Compact<Weight>, Option<Compact<u128>>, Bytes]>;
|
call: AugmentedSubmittable<(dest: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Compact<u128>, SpWeightsWeightV2Weight, Option<Compact<u128>>, Bytes]>;
|
||||||
|
/**
|
||||||
|
* Deprecated version if [`Self::call`] for use in an in-storage `Call`.
|
||||||
|
**/
|
||||||
|
callOldWeight: AugmentedSubmittable<(dest: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<u64> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Compact<u128>, Compact<u64>, Option<Compact<u128>>, Bytes]>;
|
||||||
/**
|
/**
|
||||||
* Instantiates a contract from a previously deployed wasm binary.
|
* Instantiates a contract from a previously deployed wasm binary.
|
||||||
*
|
*
|
||||||
@@ -1181,7 +1196,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* code deployment step. Instead, the `code_hash` of an on-chain deployed wasm binary
|
* code deployment step. Instead, the `code_hash` of an on-chain deployed wasm binary
|
||||||
* must be supplied.
|
* must be supplied.
|
||||||
**/
|
**/
|
||||||
instantiate: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<Weight> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, codeHash: H256 | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, Compact<Weight>, Option<Compact<u128>>, H256, Bytes, Bytes]>;
|
instantiate: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, codeHash: H256 | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, SpWeightsWeightV2Weight, Option<Compact<u128>>, H256, Bytes, Bytes]>;
|
||||||
|
/**
|
||||||
|
* Deprecated version if [`Self::instantiate`] for use in an in-storage `Call`.
|
||||||
|
**/
|
||||||
|
instantiateOldWeight: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<u64> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, codeHash: H256 | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, Compact<u64>, Option<Compact<u128>>, H256, Bytes, Bytes]>;
|
||||||
/**
|
/**
|
||||||
* Instantiates a new contract from the supplied `code` optionally transferring
|
* Instantiates a new contract from the supplied `code` optionally transferring
|
||||||
* some balance.
|
* some balance.
|
||||||
@@ -1210,7 +1229,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - The `value` is transferred to the new account.
|
* - The `value` is transferred to the new account.
|
||||||
* - The `deploy` function is executed in the context of the newly-created account.
|
* - The `deploy` function is executed in the context of the newly-created account.
|
||||||
**/
|
**/
|
||||||
instantiateWithCode: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<Weight> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, Compact<Weight>, Option<Compact<u128>>, Bytes, Bytes, Bytes]>;
|
instantiateWithCode: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, SpWeightsWeightV2Weight, Option<Compact<u128>>, Bytes, Bytes, Bytes]>;
|
||||||
|
/**
|
||||||
|
* Deprecated version if [`Self::instantiate_with_code`] for use in an in-storage `Call`.
|
||||||
|
**/
|
||||||
|
instantiateWithCodeOldWeight: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: Compact<u64> | AnyNumber | Uint8Array, storageDepositLimit: Option<Compact<u128>> | null | Uint8Array | Compact<u128> | AnyNumber, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, Compact<u64>, Option<Compact<u128>>, Bytes, Bytes, Bytes]>;
|
||||||
/**
|
/**
|
||||||
* Remove the code stored under `code_hash` and refund the deposit to its owner.
|
* Remove the code stored under `code_hash` and refund the deposit to its owner.
|
||||||
*
|
*
|
||||||
@@ -1414,7 +1437,42 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - up to 3 events
|
* - up to 3 events
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<Weight> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<Weight>, Compact<u32>]>;
|
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, SpWeightsWeightV2Weight, Compact<u32>]>;
|
||||||
|
/**
|
||||||
|
* Close a vote that is either approved, disapproved or whose voting period has ended.
|
||||||
|
*
|
||||||
|
* May be called by any signed account in order to finish voting and close the proposal.
|
||||||
|
*
|
||||||
|
* If called before the end of the voting period it will only close the vote if it is
|
||||||
|
* has enough votes to be approved or disapproved.
|
||||||
|
*
|
||||||
|
* If called after the end of the voting period abstentions are counted as rejections
|
||||||
|
* unless there is a prime member set and the prime member cast an approval.
|
||||||
|
*
|
||||||
|
* If the close operation completes successfully with disapproval, the transaction fee will
|
||||||
|
* be waived. Otherwise execution of the approved operation will be charged to the caller.
|
||||||
|
*
|
||||||
|
* + `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed
|
||||||
|
* proposal.
|
||||||
|
* + `length_bound`: The upper bound for the length of the proposal in storage. Checked via
|
||||||
|
* `storage::read` so it is `size_of::<u32>() == 4` larger than the pure length.
|
||||||
|
*
|
||||||
|
* # <weight>
|
||||||
|
* ## Weight
|
||||||
|
* - `O(B + M + P1 + P2)` where:
|
||||||
|
* - `B` is `proposal` size in bytes (length-fee-bounded)
|
||||||
|
* - `M` is members-count (code- and governance-bounded)
|
||||||
|
* - `P1` is the complexity of `proposal` preimage.
|
||||||
|
* - `P2` is proposal-count (code-bounded)
|
||||||
|
* - DB:
|
||||||
|
* - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)
|
||||||
|
* - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec
|
||||||
|
* `O(P2)`)
|
||||||
|
* - any mutations done while executing `proposal` (`P1`)
|
||||||
|
* - up to 3 events
|
||||||
|
* # </weight>
|
||||||
|
**/
|
||||||
|
closeOldWeight: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<u64> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<u64>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
||||||
* state.
|
* state.
|
||||||
@@ -1563,16 +1621,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Weight: `O(p)` where `p = PublicProps::<T>::decode_len()`
|
* Weight: `O(p)` where `p = PublicProps::<T>::decode_len()`
|
||||||
**/
|
**/
|
||||||
cancelProposal: AugmentedSubmittable<(propIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>]>;
|
cancelProposal: AugmentedSubmittable<(propIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>]>;
|
||||||
/**
|
|
||||||
* Cancel a proposal queued for enactment.
|
|
||||||
*
|
|
||||||
* The dispatch origin of this call must be _Root_.
|
|
||||||
*
|
|
||||||
* - `which`: The index of the referendum to cancel.
|
|
||||||
*
|
|
||||||
* Weight: `O(D)` where `D` is the items in the dispatch queue. Weighted as `D = 10`.
|
|
||||||
**/
|
|
||||||
cancelQueued: AugmentedSubmittable<(which: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
|
||||||
/**
|
/**
|
||||||
* Remove a referendum.
|
* Remove a referendum.
|
||||||
*
|
*
|
||||||
@@ -1625,10 +1673,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Weight: `O(1)`.
|
* Weight: `O(1)`.
|
||||||
**/
|
**/
|
||||||
emergencyCancel: AugmentedSubmittable<(refIndex: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
emergencyCancel: AugmentedSubmittable<(refIndex: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
||||||
/**
|
|
||||||
* Enact a proposal from a referendum. For now we just make the weight be the maximum.
|
|
||||||
**/
|
|
||||||
enactProposal: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, u32]>;
|
|
||||||
/**
|
/**
|
||||||
* Schedule a referendum to be tabled once it is legal to schedule an external
|
* Schedule a referendum to be tabled once it is legal to schedule an external
|
||||||
* referendum.
|
* referendum.
|
||||||
@@ -1636,11 +1680,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* The dispatch origin of this call must be `ExternalOrigin`.
|
* The dispatch origin of this call must be `ExternalOrigin`.
|
||||||
*
|
*
|
||||||
* - `proposal_hash`: The preimage hash of the proposal.
|
* - `proposal_hash`: The preimage hash of the proposal.
|
||||||
*
|
|
||||||
* Weight: `O(V)` with V number of vetoers in the blacklist of proposal.
|
|
||||||
* Decoding vec of length V. Charged as maximum
|
|
||||||
**/
|
**/
|
||||||
externalPropose: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
externalPropose: AugmentedSubmittable<(proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [FrameSupportPreimagesBounded]>;
|
||||||
/**
|
/**
|
||||||
* Schedule a negative-turnout-bias referendum to be tabled next once it is legal to
|
* Schedule a negative-turnout-bias referendum to be tabled next once it is legal to
|
||||||
* schedule an external referendum.
|
* schedule an external referendum.
|
||||||
@@ -1654,7 +1695,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* Weight: `O(1)`
|
* Weight: `O(1)`
|
||||||
**/
|
**/
|
||||||
externalProposeDefault: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
externalProposeDefault: AugmentedSubmittable<(proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [FrameSupportPreimagesBounded]>;
|
||||||
/**
|
/**
|
||||||
* Schedule a majority-carries referendum to be tabled next once it is legal to schedule
|
* Schedule a majority-carries referendum to be tabled next once it is legal to schedule
|
||||||
* an external referendum.
|
* an external referendum.
|
||||||
@@ -1668,7 +1709,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* Weight: `O(1)`
|
* Weight: `O(1)`
|
||||||
**/
|
**/
|
||||||
externalProposeMajority: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
externalProposeMajority: AugmentedSubmittable<(proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [FrameSupportPreimagesBounded]>;
|
||||||
/**
|
/**
|
||||||
* Schedule the currently externally-proposed majority-carries referendum to be tabled
|
* Schedule the currently externally-proposed majority-carries referendum to be tabled
|
||||||
* immediately. If there is no externally-proposed referendum currently, or if there is one
|
* immediately. If there is no externally-proposed referendum currently, or if there is one
|
||||||
@@ -1677,7 +1718,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* The dispatch of this call must be `FastTrackOrigin`.
|
* The dispatch of this call must be `FastTrackOrigin`.
|
||||||
*
|
*
|
||||||
* - `proposal_hash`: The hash of the current external proposal.
|
* - `proposal_hash`: The hash of the current external proposal.
|
||||||
* - `voting_period`: The period that is allowed for voting on this proposal.
|
* - `voting_period`: The period that is allowed for voting on this proposal. Increased to
|
||||||
* Must be always greater than zero.
|
* Must be always greater than zero.
|
||||||
* For `FastTrackOrigin` must be equal or greater than `FastTrackVotingPeriod`.
|
* For `FastTrackOrigin` must be equal or greater than `FastTrackVotingPeriod`.
|
||||||
* - `delay`: The number of block after voting has ended in approval and this should be
|
* - `delay`: The number of block after voting has ended in approval and this should be
|
||||||
@@ -1688,42 +1729,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Weight: `O(1)`
|
* Weight: `O(1)`
|
||||||
**/
|
**/
|
||||||
fastTrack: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, votingPeriod: u32 | AnyNumber | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, u32, u32]>;
|
fastTrack: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, votingPeriod: u32 | AnyNumber | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, u32, u32]>;
|
||||||
/**
|
|
||||||
* Register the preimage for an upcoming proposal. This requires the proposal to be
|
|
||||||
* in the dispatch queue. No deposit is needed. When this call is successful, i.e.
|
|
||||||
* the preimage has not been uploaded before and matches some imminent proposal,
|
|
||||||
* no fee is paid.
|
|
||||||
*
|
|
||||||
* The dispatch origin of this call must be _Signed_.
|
|
||||||
*
|
|
||||||
* - `encoded_proposal`: The preimage of a proposal.
|
|
||||||
*
|
|
||||||
* Emits `PreimageNoted`.
|
|
||||||
*
|
|
||||||
* Weight: `O(E)` with E size of `encoded_proposal` (protected by a required deposit).
|
|
||||||
**/
|
|
||||||
noteImminentPreimage: AugmentedSubmittable<(encodedProposal: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;
|
|
||||||
/**
|
|
||||||
* Same as `note_imminent_preimage` but origin is `OperationalPreimageOrigin`.
|
|
||||||
**/
|
|
||||||
noteImminentPreimageOperational: AugmentedSubmittable<(encodedProposal: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;
|
|
||||||
/**
|
|
||||||
* Register the preimage for an upcoming proposal. This doesn't require the proposal to be
|
|
||||||
* in the dispatch queue but does require a deposit, returned once enacted.
|
|
||||||
*
|
|
||||||
* The dispatch origin of this call must be _Signed_.
|
|
||||||
*
|
|
||||||
* - `encoded_proposal`: The preimage of a proposal.
|
|
||||||
*
|
|
||||||
* Emits `PreimageNoted`.
|
|
||||||
*
|
|
||||||
* Weight: `O(E)` with E size of `encoded_proposal` (protected by a required deposit).
|
|
||||||
**/
|
|
||||||
notePreimage: AugmentedSubmittable<(encodedProposal: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;
|
|
||||||
/**
|
|
||||||
* Same as `note_preimage` but origin is `OperationalPreimageOrigin`.
|
|
||||||
**/
|
|
||||||
notePreimageOperational: AugmentedSubmittable<(encodedProposal: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;
|
|
||||||
/**
|
/**
|
||||||
* Propose a sensitive action to be taken.
|
* Propose a sensitive action to be taken.
|
||||||
*
|
*
|
||||||
@@ -1734,28 +1739,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `value`: The amount of deposit (must be at least `MinimumDeposit`).
|
* - `value`: The amount of deposit (must be at least `MinimumDeposit`).
|
||||||
*
|
*
|
||||||
* Emits `Proposed`.
|
* Emits `Proposed`.
|
||||||
*
|
|
||||||
* Weight: `O(p)`
|
|
||||||
**/
|
**/
|
||||||
propose: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u128>]>;
|
propose: AugmentedSubmittable<(proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [FrameSupportPreimagesBounded, Compact<u128>]>;
|
||||||
/**
|
|
||||||
* Remove an expired proposal preimage and collect the deposit.
|
|
||||||
*
|
|
||||||
* The dispatch origin of this call must be _Signed_.
|
|
||||||
*
|
|
||||||
* - `proposal_hash`: The preimage hash of a proposal.
|
|
||||||
* - `proposal_length_upper_bound`: an upper bound on length of the proposal. Extrinsic is
|
|
||||||
* weighted according to this value with no refund.
|
|
||||||
*
|
|
||||||
* This will only work after `VotingPeriod` blocks from the time that the preimage was
|
|
||||||
* noted, if it's the same account doing it. If it's a different account, then it'll only
|
|
||||||
* work an additional `EnactmentPeriod` later.
|
|
||||||
*
|
|
||||||
* Emits `PreimageReaped`.
|
|
||||||
*
|
|
||||||
* Weight: `O(D)` where D is length of proposal.
|
|
||||||
**/
|
|
||||||
reapPreimage: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, proposalLenUpperBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>]>;
|
|
||||||
/**
|
/**
|
||||||
* Remove a vote for a referendum.
|
* Remove a vote for a referendum.
|
||||||
*
|
*
|
||||||
@@ -1811,12 +1796,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* must have funds to cover the deposit, equal to the original deposit.
|
* must have funds to cover the deposit, equal to the original deposit.
|
||||||
*
|
*
|
||||||
* - `proposal`: The index of the proposal to second.
|
* - `proposal`: The index of the proposal to second.
|
||||||
* - `seconds_upper_bound`: an upper bound on the current number of seconds on this
|
|
||||||
* proposal. Extrinsic is weighted according to this value with no refund.
|
|
||||||
*
|
|
||||||
* Weight: `O(S)` where S is the number of seconds a proposal already has.
|
|
||||||
**/
|
**/
|
||||||
second: AugmentedSubmittable<(proposal: Compact<u32> | AnyNumber | Uint8Array, secondsUpperBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, Compact<u32>]>;
|
second: AugmentedSubmittable<(proposal: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Undelegate the voting power of the sending account.
|
* Undelegate the voting power of the sending account.
|
||||||
*
|
*
|
||||||
@@ -1862,8 +1843,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* - `ref_index`: The index of the referendum to vote for.
|
* - `ref_index`: The index of the referendum to vote for.
|
||||||
* - `vote`: The vote configuration.
|
* - `vote`: The vote configuration.
|
||||||
*
|
|
||||||
* Weight: `O(R)` where R is the number of referendums the voter has voted on.
|
|
||||||
**/
|
**/
|
||||||
vote: AugmentedSubmittable<(refIndex: Compact<u32> | AnyNumber | Uint8Array, vote: PalletDemocracyVoteAccountVote | { Standard: any } | { Split: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, PalletDemocracyVoteAccountVote]>;
|
vote: AugmentedSubmittable<(refIndex: Compact<u32> | AnyNumber | Uint8Array, vote: PalletDemocracyVoteAccountVote | { Standard: any } | { Split: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, PalletDemocracyVoteAccountVote]>;
|
||||||
/**
|
/**
|
||||||
@@ -2045,6 +2024,49 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
};
|
};
|
||||||
|
fastUnstake: {
|
||||||
|
/**
|
||||||
|
* Control the operation of this pallet.
|
||||||
|
*
|
||||||
|
* Dispatch origin must be signed by the [`Config::ControlOrigin`].
|
||||||
|
**/
|
||||||
|
control: AugmentedSubmittable<(uncheckedErasToCheck: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
|
||||||
|
/**
|
||||||
|
* Deregister oneself from the fast-unstake.
|
||||||
|
*
|
||||||
|
* This is useful if one is registered, they are still waiting, and they change their mind.
|
||||||
|
*
|
||||||
|
* Note that the associated stash is still fully unbonded and chilled as a consequence of
|
||||||
|
* calling `register_fast_unstake`. This should probably be followed by a call to
|
||||||
|
* `Staking::rebond`.
|
||||||
|
**/
|
||||||
|
deregister: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Register oneself for fast-unstake.
|
||||||
|
*
|
||||||
|
* The dispatch origin of this call must be signed by the controller account, similar to
|
||||||
|
* `staking::unbond`.
|
||||||
|
*
|
||||||
|
* The stash associated with the origin must have no ongoing unlocking chunks. If
|
||||||
|
* successful, this will fully unbond and chill the stash. Then, it will enqueue the stash
|
||||||
|
* to be checked in further blocks.
|
||||||
|
*
|
||||||
|
* If by the time this is called, the stash is actually eligible for fast-unstake, then
|
||||||
|
* they are guaranteed to remain eligible, because the call will chill them as well.
|
||||||
|
*
|
||||||
|
* If the check works, the entire staking data is removed, i.e. the stash is fully
|
||||||
|
* unstaked.
|
||||||
|
*
|
||||||
|
* If the check fails, the stash remains chilled and waiting for being unbonded as in with
|
||||||
|
* the normal staking system, but they lose part of their unbonding chunks due to consuming
|
||||||
|
* the chain's resources.
|
||||||
|
**/
|
||||||
|
registerFastUnstake: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
|
/**
|
||||||
|
* Generic tx
|
||||||
|
**/
|
||||||
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
|
};
|
||||||
gilt: {
|
gilt: {
|
||||||
/**
|
/**
|
||||||
* Place a bid for a gilt to be issued.
|
* Place a bid for a gilt to be issued.
|
||||||
@@ -2625,7 +2647,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - Write: Multisig Storage, [Caller Account]
|
* - Write: Multisig Storage, [Caller Account]
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
approveAsMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], maybeTimepoint: Option<PalletMultisigTimepoint> | null | Uint8Array | PalletMultisigTimepoint | { height?: any; index?: any } | string, callHash: U8aFixed | string | Uint8Array, maxWeight: Weight | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, Option<PalletMultisigTimepoint>, U8aFixed, Weight]>;
|
approveAsMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], maybeTimepoint: Option<PalletMultisigTimepoint> | null | Uint8Array | PalletMultisigTimepoint | { height?: any; index?: any } | string, callHash: U8aFixed | string | Uint8Array, maxWeight: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, Option<PalletMultisigTimepoint>, U8aFixed, SpWeightsWeightV2Weight]>;
|
||||||
/**
|
/**
|
||||||
* Register approval for a dispatch to be made from a deterministic composite account if
|
* Register approval for a dispatch to be made from a deterministic composite account if
|
||||||
* approved by a total of `threshold - 1` of `other_signatories`.
|
* approved by a total of `threshold - 1` of `other_signatories`.
|
||||||
@@ -2668,12 +2690,12 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* taken for its lifetime of `DepositBase + threshold * DepositFactor`.
|
* taken for its lifetime of `DepositBase + threshold * DepositFactor`.
|
||||||
* -------------------------------
|
* -------------------------------
|
||||||
* - DB Weight:
|
* - DB Weight:
|
||||||
* - Reads: Multisig Storage, [Caller Account], Calls (if `store_call`)
|
* - Reads: Multisig Storage, [Caller Account]
|
||||||
* - Writes: Multisig Storage, [Caller Account], Calls (if `store_call`)
|
* - Writes: Multisig Storage, [Caller Account]
|
||||||
* - Plus Call Weight
|
* - Plus Call Weight
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
asMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], maybeTimepoint: Option<PalletMultisigTimepoint> | null | Uint8Array | PalletMultisigTimepoint | { height?: any; index?: any } | string, call: WrapperKeepOpaque<Call> | object | string | Uint8Array, storeCall: bool | boolean | Uint8Array, maxWeight: Weight | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, Option<PalletMultisigTimepoint>, WrapperKeepOpaque<Call>, bool, Weight]>;
|
asMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], maybeTimepoint: Option<PalletMultisigTimepoint> | null | Uint8Array | PalletMultisigTimepoint | { height?: any; index?: any } | string, call: Call | IMethod | string | Uint8Array, maxWeight: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, Option<PalletMultisigTimepoint>, Call, SpWeightsWeightV2Weight]>;
|
||||||
/**
|
/**
|
||||||
* Immediately dispatch a multi-signature call using a single approval from the caller.
|
* Immediately dispatch a multi-signature call using a single approval from the caller.
|
||||||
*
|
*
|
||||||
@@ -2717,8 +2739,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - Storage: removes one item.
|
* - Storage: removes one item.
|
||||||
* ----------------------------------
|
* ----------------------------------
|
||||||
* - DB Weight:
|
* - DB Weight:
|
||||||
* - Read: Multisig Storage, [Caller Account], Refund Account, Calls
|
* - Read: Multisig Storage, [Caller Account], Refund Account
|
||||||
* - Write: Multisig Storage, [Caller Account], Refund Account, Calls
|
* - Write: Multisig Storage, [Caller Account], Refund Account
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
cancelAsMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], timepoint: PalletMultisigTimepoint | { height?: any; index?: any } | string | Uint8Array, callHash: U8aFixed | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, PalletMultisigTimepoint, U8aFixed]>;
|
cancelAsMulti: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], timepoint: PalletMultisigTimepoint | { height?: any; index?: any } | string | Uint8Array, callHash: U8aFixed | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, PalletMultisigTimepoint, U8aFixed]>;
|
||||||
@@ -2926,6 +2948,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
requestPreimage: AugmentedSubmittable<(hash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
requestPreimage: AugmentedSubmittable<(hash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
||||||
/**
|
/**
|
||||||
* Clear an unrequested preimage from the runtime storage.
|
* Clear an unrequested preimage from the runtime storage.
|
||||||
|
*
|
||||||
|
* If `len` is provided, then it will be a much cheaper operation.
|
||||||
|
*
|
||||||
|
* - `hash`: The hash of the preimage to be removed from the store.
|
||||||
|
* - `len`: The length of the preimage of `hash`.
|
||||||
**/
|
**/
|
||||||
unnotePreimage: AugmentedSubmittable<(hash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
unnotePreimage: AugmentedSubmittable<(hash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2950,10 +2977,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `proxy_type`: The permissions allowed for this proxy account.
|
* - `proxy_type`: The permissions allowed for this proxy account.
|
||||||
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
* - `delay`: The announcement period required of the initial proxy. Will generally be
|
||||||
* zero.
|
* zero.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u32]>;
|
addProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -2972,12 +2995,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
announce: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -2999,36 +3016,27 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* same sender, with the same parameters.
|
* same sender, with the same parameters.
|
||||||
*
|
*
|
||||||
* Fails if there are insufficient funds to pay for deposit.
|
* Fails if there are insufficient funds to pay for deposit.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
* TODO: Might be over counting 1 read
|
|
||||||
**/
|
**/
|
||||||
anonymous: AugmentedSubmittable<(proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeProxyType, u32, u16]>;
|
createPure: AugmentedSubmittable<(proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array, index: u16 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeProxyType, u32, u16]>;
|
||||||
/**
|
/**
|
||||||
* Removes a previously spawned anonymous proxy.
|
* Removes a previously spawned pure proxy.
|
||||||
*
|
*
|
||||||
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
* WARNING: **All access to this account will be lost.** Any funds held in it will be
|
||||||
* inaccessible.
|
* inaccessible.
|
||||||
*
|
*
|
||||||
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
* Requires a `Signed` origin, and the sender account must have been created by a call to
|
||||||
* `anonymous` with corresponding parameters.
|
* `pure` with corresponding parameters.
|
||||||
*
|
*
|
||||||
* - `spawner`: The account that originally called `anonymous` to create this account.
|
* - `spawner`: The account that originally called `pure` to create this account.
|
||||||
* - `index`: The disambiguation index originally passed to `anonymous`. Probably `0`.
|
* - `index`: The disambiguation index originally passed to `pure`. Probably `0`.
|
||||||
* - `proxy_type`: The proxy type originally passed to `anonymous`.
|
* - `proxy_type`: The proxy type originally passed to `pure`.
|
||||||
* - `height`: The height of the chain when the call to `anonymous` was processed.
|
* - `height`: The height of the chain when the call to `pure` was processed.
|
||||||
* - `ext_index`: The extrinsic index in which the call to `anonymous` was processed.
|
* - `ext_index`: The extrinsic index in which the call to `pure` was processed.
|
||||||
*
|
*
|
||||||
* Fails with `NoPermission` in case the caller is not a previously created anonymous
|
* Fails with `NoPermission` in case the caller is not a previously created pure
|
||||||
* account whose `anonymous` call has corresponding parameters.
|
* account whose `pure` call has corresponding parameters.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
killAnonymous: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
killPure: AugmentedSubmittable<(spawner: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u16, Compact<u32>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Dispatch the given `call` from an account that the sender is authorised for through
|
* Dispatch the given `call` from an account that the sender is authorised for through
|
||||||
* `add_proxy`.
|
* `add_proxy`.
|
||||||
@@ -3041,10 +3049,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KitchensinkRuntimeProxyType> | null | Uint8Array | KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<KitchensinkRuntimeProxyType>, Call]>;
|
proxy: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KitchensinkRuntimeProxyType> | null | Uint8Array | KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Option<KitchensinkRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -3059,12 +3063,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
* - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call.
|
||||||
* - `call`: The call to be made by the `real` account.
|
* - `call`: The call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KitchensinkRuntimeProxyType> | null | Uint8Array | KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<KitchensinkRuntimeProxyType>, Call]>;
|
proxyAnnounced: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, forceProxyType: Option<KitchensinkRuntimeProxyType> | null | Uint8Array | KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, Option<KitchensinkRuntimeProxyType>, Call]>;
|
||||||
/**
|
/**
|
||||||
@@ -3078,12 +3076,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `delegate`: The account that previously announced the call.
|
* - `delegate`: The account that previously announced the call.
|
||||||
* - `call_hash`: The hash of the call to be made.
|
* - `call_hash`: The hash of the call to be made.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
rejectAnnouncement: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -3097,12 +3089,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `real`: The account that the proxy will make a call on behalf of.
|
* - `real`: The account that the proxy will make a call on behalf of.
|
||||||
* - `call_hash`: The hash of the call to be made by the `real` account.
|
* - `call_hash`: The hash of the call to be made by the `real` account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of:
|
|
||||||
* - A: the number of announcements made.
|
|
||||||
* - P: the number of proxies the user has.
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
removeAnnouncement: AugmentedSubmittable<(real: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
|
||||||
/**
|
/**
|
||||||
@@ -3110,12 +3096,8 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
*
|
*
|
||||||
* The dispatch origin for this call must be _Signed_.
|
* The dispatch origin for this call must be _Signed_.
|
||||||
*
|
*
|
||||||
* WARNING: This may be called on accounts created by `anonymous`, however if done, then
|
* WARNING: This may be called on accounts created by `pure`, however if done, then
|
||||||
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
* the unreserved fees will be inaccessible. **All access to this account will be lost.**
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
removeProxies: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
|
||||||
/**
|
/**
|
||||||
@@ -3126,10 +3108,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Parameters:
|
* Parameters:
|
||||||
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
* - `proxy`: The account that the `caller` would like to remove as a proxy.
|
||||||
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
* - `proxy_type`: The permissions currently enabled for the removed proxy account.
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* Weight is a function of the number of proxies the user has (P).
|
|
||||||
* # </weight>
|
|
||||||
**/
|
**/
|
||||||
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u32]>;
|
removeProxy: AugmentedSubmittable<(delegate: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, proxyType: KitchensinkRuntimeProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | number | Uint8Array, delay: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KitchensinkRuntimeProxyType, u32]>;
|
||||||
/**
|
/**
|
||||||
@@ -3274,12 +3252,12 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds
|
* - `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds
|
||||||
* available.
|
* available.
|
||||||
* - `proposal_origin`: The origin from which the proposal should be executed.
|
* - `proposal_origin`: The origin from which the proposal should be executed.
|
||||||
* - `proposal_hash`: The hash of the proposal preimage.
|
* - `proposal`: The proposal.
|
||||||
* - `enactment_moment`: The moment that the proposal should be enacted.
|
* - `enactment_moment`: The moment that the proposal should be enacted.
|
||||||
*
|
*
|
||||||
* Emits `Submitted`.
|
* Emits `Submitted`.
|
||||||
**/
|
**/
|
||||||
submit: AugmentedSubmittable<(proposalOrigin: KitchensinkRuntimeOriginCaller | { system: any } | { Void: any } | { Council: any } | { TechnicalCommittee: any } | { AllianceMotion: any } | string | Uint8Array, proposalHash: H256 | string | Uint8Array, enactmentMoment: FrameSupportScheduleDispatchTime | { At: any } | { After: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeOriginCaller, H256, FrameSupportScheduleDispatchTime]>;
|
submit: AugmentedSubmittable<(proposalOrigin: KitchensinkRuntimeOriginCaller | { system: any } | { Void: any } | { Council: any } | { TechnicalCommittee: any } | { AllianceMotion: any } | string | Uint8Array, proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array, enactmentMoment: FrameSupportScheduleDispatchTime | { At: any } | { After: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeOriginCaller, FrameSupportPreimagesBounded, FrameSupportScheduleDispatchTime]>;
|
||||||
/**
|
/**
|
||||||
* Generic tx
|
* Generic tx
|
||||||
**/
|
**/
|
||||||
@@ -3476,12 +3454,12 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds
|
* - `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds
|
||||||
* available.
|
* available.
|
||||||
* - `proposal_origin`: The origin from which the proposal should be executed.
|
* - `proposal_origin`: The origin from which the proposal should be executed.
|
||||||
* - `proposal_hash`: The hash of the proposal preimage.
|
* - `proposal`: The proposal.
|
||||||
* - `enactment_moment`: The moment that the proposal should be enacted.
|
* - `enactment_moment`: The moment that the proposal should be enacted.
|
||||||
*
|
*
|
||||||
* Emits `Submitted`.
|
* Emits `Submitted`.
|
||||||
**/
|
**/
|
||||||
submit: AugmentedSubmittable<(proposalOrigin: KitchensinkRuntimeOriginCaller | { system: any } | { Void: any } | { Council: any } | { TechnicalCommittee: any } | { AllianceMotion: any } | string | Uint8Array, proposalHash: H256 | string | Uint8Array, enactmentMoment: FrameSupportScheduleDispatchTime | { At: any } | { After: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeOriginCaller, H256, FrameSupportScheduleDispatchTime]>;
|
submit: AugmentedSubmittable<(proposalOrigin: KitchensinkRuntimeOriginCaller | { system: any } | { Void: any } | { Council: any } | { TechnicalCommittee: any } | { AllianceMotion: any } | string | Uint8Array, proposal: FrameSupportPreimagesBounded | { Legacy: any } | { Inline: any } | { Lookup: any } | string | Uint8Array, enactmentMoment: FrameSupportScheduleDispatchTime | { At: any } | { After: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [KitchensinkRuntimeOriginCaller, FrameSupportPreimagesBounded, FrameSupportScheduleDispatchTime]>;
|
||||||
/**
|
/**
|
||||||
* Generic tx
|
* Generic tx
|
||||||
**/
|
**/
|
||||||
@@ -3505,11 +3483,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
/**
|
/**
|
||||||
* Cancel a named scheduled task.
|
* Cancel a named scheduled task.
|
||||||
**/
|
**/
|
||||||
cancelNamed: AugmentedSubmittable<(id: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;
|
cancelNamed: AugmentedSubmittable<(id: U8aFixed | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [U8aFixed]>;
|
||||||
/**
|
/**
|
||||||
* Anonymously schedule a task.
|
* Anonymously schedule a task.
|
||||||
**/
|
**/
|
||||||
schedule: AugmentedSubmittable<(when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: FrameSupportScheduleMaybeHashed | { Value: any } | { Hash: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, FrameSupportScheduleMaybeHashed]>;
|
schedule: AugmentedSubmittable<(when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, Call]>;
|
||||||
/**
|
/**
|
||||||
* Anonymously schedule a task after a delay.
|
* Anonymously schedule a task after a delay.
|
||||||
*
|
*
|
||||||
@@ -3517,11 +3495,11 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Same as [`schedule`].
|
* Same as [`schedule`].
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
scheduleAfter: AugmentedSubmittable<(after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: FrameSupportScheduleMaybeHashed | { Value: any } | { Hash: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, FrameSupportScheduleMaybeHashed]>;
|
scheduleAfter: AugmentedSubmittable<(after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, Call]>;
|
||||||
/**
|
/**
|
||||||
* Schedule a named task.
|
* Schedule a named task.
|
||||||
**/
|
**/
|
||||||
scheduleNamed: AugmentedSubmittable<(id: Bytes | string | Uint8Array, when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: FrameSupportScheduleMaybeHashed | { Value: any } | { Hash: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes, u32, Option<ITuple<[u32, u32]>>, u8, FrameSupportScheduleMaybeHashed]>;
|
scheduleNamed: AugmentedSubmittable<(id: U8aFixed | string | Uint8Array, when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [U8aFixed, u32, Option<ITuple<[u32, u32]>>, u8, Call]>;
|
||||||
/**
|
/**
|
||||||
* Schedule a named task after a delay.
|
* Schedule a named task after a delay.
|
||||||
*
|
*
|
||||||
@@ -3529,7 +3507,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* Same as [`schedule_named`](Self::schedule_named).
|
* Same as [`schedule_named`](Self::schedule_named).
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
scheduleNamedAfter: AugmentedSubmittable<(id: Bytes | string | Uint8Array, after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: FrameSupportScheduleMaybeHashed | { Value: any } | { Hash: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes, u32, Option<ITuple<[u32, u32]>>, u8, FrameSupportScheduleMaybeHashed]>;
|
scheduleNamedAfter: AugmentedSubmittable<(id: U8aFixed | string | Uint8Array, after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | Uint8Array | ITuple<[u32, u32]> | [u32 | AnyNumber | Uint8Array, u32 | AnyNumber | Uint8Array], priority: u8 | AnyNumber | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [U8aFixed, u32, Option<ITuple<[u32, u32]>>, u8, Call]>;
|
||||||
/**
|
/**
|
||||||
* Generic tx
|
* Generic tx
|
||||||
**/
|
**/
|
||||||
@@ -4173,31 +4151,6 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
setController: AugmentedSubmittable<(controller: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
||||||
/**
|
|
||||||
* Set `HistoryDepth` value. This function will delete any history information
|
|
||||||
* when `HistoryDepth` is reduced.
|
|
||||||
*
|
|
||||||
* Parameters:
|
|
||||||
* - `new_history_depth`: The new history depth you would like to set.
|
|
||||||
* - `era_items_deleted`: The number of items that will be deleted by this dispatch. This
|
|
||||||
* should report all the storage items that will be deleted by clearing old era history.
|
|
||||||
* Needed to report an accurate weight for the dispatch. Trusted by `Root` to report an
|
|
||||||
* accurate number.
|
|
||||||
*
|
|
||||||
* Origin must be root.
|
|
||||||
*
|
|
||||||
* # <weight>
|
|
||||||
* - E: Number of history depths removed, i.e. 10 -> 7 = 3
|
|
||||||
* - Weight: O(E)
|
|
||||||
* - DB Weight:
|
|
||||||
* - Reads: Current Era, History Depth
|
|
||||||
* - Writes: History Depth
|
|
||||||
* - Clear Prefix Each: Era Stakers, EraStakersClipped, ErasValidatorPrefs
|
|
||||||
* - Writes Each: ErasValidatorReward, ErasRewardPoints, ErasTotalStake,
|
|
||||||
* ErasStartSessionIndex
|
|
||||||
* # </weight>
|
|
||||||
**/
|
|
||||||
setHistoryDepth: AugmentedSubmittable<(newHistoryDepth: Compact<u32> | AnyNumber | Uint8Array, eraItemsDeleted: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, Compact<u32>]>;
|
|
||||||
/**
|
/**
|
||||||
* Set the validators who cannot be slashed (if any).
|
* Set the validators who cannot be slashed (if any).
|
||||||
*
|
*
|
||||||
@@ -4237,7 +4190,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
* * `min_commission`: The minimum amount of commission that each validators must maintain.
|
||||||
* This is checked only upon calling `validate`. Existing validators are not affected.
|
* This is checked only upon calling `validate`. Existing validators are not affected.
|
||||||
*
|
*
|
||||||
* Origin must be Root to call this function.
|
* RuntimeOrigin must be Root to call this function.
|
||||||
*
|
*
|
||||||
* NOTE: Existing nominators and validators will not be affected by this update.
|
* NOTE: Existing nominators and validators will not be affected by this update.
|
||||||
* to kick people under the new limits, `chill_other` should be called.
|
* to kick people under the new limits, `chill_other` should be called.
|
||||||
@@ -4428,7 +4381,7 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - The weight of this call is defined by the caller.
|
* - The weight of this call is defined by the caller.
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
sudoUncheckedWeight: AugmentedSubmittable<(call: Call | IMethod | string | Uint8Array, weight: Weight | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call, Weight]>;
|
sudoUncheckedWeight: AugmentedSubmittable<(call: Call | IMethod | string | Uint8Array, weight: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call, SpWeightsWeightV2Weight]>;
|
||||||
/**
|
/**
|
||||||
* Generic tx
|
* Generic tx
|
||||||
**/
|
**/
|
||||||
@@ -4537,7 +4490,42 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
* - up to 3 events
|
* - up to 3 events
|
||||||
* # </weight>
|
* # </weight>
|
||||||
**/
|
**/
|
||||||
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<Weight> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<Weight>, Compact<u32>]>;
|
close: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, SpWeightsWeightV2Weight, Compact<u32>]>;
|
||||||
|
/**
|
||||||
|
* Close a vote that is either approved, disapproved or whose voting period has ended.
|
||||||
|
*
|
||||||
|
* May be called by any signed account in order to finish voting and close the proposal.
|
||||||
|
*
|
||||||
|
* If called before the end of the voting period it will only close the vote if it is
|
||||||
|
* has enough votes to be approved or disapproved.
|
||||||
|
*
|
||||||
|
* If called after the end of the voting period abstentions are counted as rejections
|
||||||
|
* unless there is a prime member set and the prime member cast an approval.
|
||||||
|
*
|
||||||
|
* If the close operation completes successfully with disapproval, the transaction fee will
|
||||||
|
* be waived. Otherwise execution of the approved operation will be charged to the caller.
|
||||||
|
*
|
||||||
|
* + `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed
|
||||||
|
* proposal.
|
||||||
|
* + `length_bound`: The upper bound for the length of the proposal in storage. Checked via
|
||||||
|
* `storage::read` so it is `size_of::<u32>() == 4` larger than the pure length.
|
||||||
|
*
|
||||||
|
* # <weight>
|
||||||
|
* ## Weight
|
||||||
|
* - `O(B + M + P1 + P2)` where:
|
||||||
|
* - `B` is `proposal` size in bytes (length-fee-bounded)
|
||||||
|
* - `M` is members-count (code- and governance-bounded)
|
||||||
|
* - `P1` is the complexity of `proposal` preimage.
|
||||||
|
* - `P2` is proposal-count (code-bounded)
|
||||||
|
* - DB:
|
||||||
|
* - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)
|
||||||
|
* - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec
|
||||||
|
* `O(P2)`)
|
||||||
|
* - any mutations done while executing `proposal` (`P1`)
|
||||||
|
* - up to 3 events
|
||||||
|
* # </weight>
|
||||||
|
**/
|
||||||
|
closeOldWeight: AugmentedSubmittable<(proposalHash: H256 | string | Uint8Array, index: Compact<u32> | AnyNumber | Uint8Array, proposalWeightBound: Compact<u64> | AnyNumber | Uint8Array, lengthBound: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Compact<u32>, Compact<u64>, Compact<u32>]>;
|
||||||
/**
|
/**
|
||||||
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
* Disapprove a proposal, close, and remove it from the system, regardless of its current
|
||||||
* state.
|
* state.
|
||||||
@@ -5602,8 +5590,38 @@ declare module '@polkadot/api-base/types/submittable' {
|
|||||||
**/
|
**/
|
||||||
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
};
|
};
|
||||||
|
voterList: {
|
||||||
|
/**
|
||||||
|
* Move the caller's Id directly in front of `lighter`.
|
||||||
|
*
|
||||||
|
* The dispatch origin for this call must be _Signed_ and can only be called by the Id of
|
||||||
|
* the account going in front of `lighter`.
|
||||||
|
*
|
||||||
|
* Only works if
|
||||||
|
* - both nodes are within the same bag,
|
||||||
|
* - and `origin` has a greater `Score` than `lighter`.
|
||||||
|
**/
|
||||||
|
putInFrontOf: AugmentedSubmittable<(lighter: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
||||||
|
/**
|
||||||
|
* Declare that some `dislocated` account has, through rewards or penalties, sufficiently
|
||||||
|
* changed its score that it should properly fall into a different bag than its current
|
||||||
|
* one.
|
||||||
|
*
|
||||||
|
* Anyone can call this function about any potentially dislocated account.
|
||||||
|
*
|
||||||
|
* Will always update the stored score of `dislocated` to the correct score, based on
|
||||||
|
* `ScoreProvider`.
|
||||||
|
*
|
||||||
|
* If `dislocated` does not exists, it returns an error.
|
||||||
|
**/
|
||||||
|
rebag: AugmentedSubmittable<(dislocated: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;
|
||||||
|
/**
|
||||||
|
* Generic tx
|
||||||
|
**/
|
||||||
|
[key: string]: SubmittableExtrinsicFunction<ApiType>;
|
||||||
|
};
|
||||||
whitelist: {
|
whitelist: {
|
||||||
dispatchWhitelistedCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array, callWeightWitness: Weight | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, Weight]>;
|
dispatchWhitelistedCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array, callWeightWitness: SpWeightsWeightV2Weight | { refTime?: any; proofSize?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256, SpWeightsWeightV2Weight]>;
|
||||||
dispatchWhitelistedCallWithPreimage: AugmentedSubmittable<(call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call]>;
|
dispatchWhitelistedCallWithPreimage: AugmentedSubmittable<(call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call]>;
|
||||||
removeWhitelistedCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
removeWhitelistedCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
||||||
whitelistCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
whitelistCall: AugmentedSubmittable<(callHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
|
||||||
|
|||||||
@@ -20,13 +20,13 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/rpc-core": "9.4.1",
|
"@polkadot/rpc-core": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"rxjs": "^7.5.6"
|
"rxjs": "^7.5.7"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/api-base', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/api-base', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,20 +20,20 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/api": "9.4.1",
|
"@polkadot/api": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/types-create": "9.4.1",
|
"@polkadot/types-create": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/util-crypto": "^10.1.8",
|
"@polkadot/util-crypto": "^10.1.11",
|
||||||
"rxjs": "^7.5.6"
|
"rxjs": "^7.5.7"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/keyring": "^10.1.8"
|
"@polkadot/keyring": "^10.1.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
// SPDX-License-Identifier: Apache-2.0
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
||||||
import type { Registry } from '@polkadot/types/types';
|
import type { INumber, Registry } from '@polkadot/types/types';
|
||||||
|
|
||||||
import { ApiBase } from '@polkadot/api/base';
|
import { ApiBase } from '@polkadot/api/base';
|
||||||
import { isFunction } from '@polkadot/util';
|
import { isFunction } from '@polkadot/util';
|
||||||
@@ -16,14 +16,9 @@ export abstract class Base<ApiType extends ApiTypes> {
|
|||||||
|
|
||||||
protected readonly _decorateMethod: DecorateMethod<ApiType>;
|
protected readonly _decorateMethod: DecorateMethod<ApiType>;
|
||||||
|
|
||||||
|
protected readonly _isOldWeight: boolean;
|
||||||
|
|
||||||
constructor (api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, decorateMethod: DecorateMethod<ApiType>) {
|
constructor (api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, decorateMethod: DecorateMethod<ApiType>) {
|
||||||
this.abi = abi instanceof Abi
|
|
||||||
? abi
|
|
||||||
: new Abi(abi, api.registry.getChainProperties());
|
|
||||||
this.api = api;
|
|
||||||
|
|
||||||
this._decorateMethod = decorateMethod;
|
|
||||||
|
|
||||||
if (!api || !api.isConnected || !api.tx) {
|
if (!api || !api.isConnected || !api.tx) {
|
||||||
throw new Error('Your API has not been initialized correctly and is not connected to a chain');
|
throw new Error('Your API has not been initialized correctly and is not connected to a chain');
|
||||||
} else if (!api.tx.contracts || !isFunction(api.tx.contracts.instantiateWithCode) || api.tx.contracts.instantiateWithCode.meta.args.length !== 6) {
|
} else if (!api.tx.contracts || !isFunction(api.tx.contracts.instantiateWithCode) || api.tx.contracts.instantiateWithCode.meta.args.length !== 6) {
|
||||||
@@ -31,6 +26,13 @@ export abstract class Base<ApiType extends ApiTypes> {
|
|||||||
} else if (!api.call.contractsApi || !isFunction(api.call.contractsApi.call)) {
|
} else if (!api.call.contractsApi || !isFunction(api.call.contractsApi.call)) {
|
||||||
throw new Error('Your runtime does not expose the api.call.contractsApi.call runtime interfaces');
|
throw new Error('Your runtime does not expose the api.call.contractsApi.call runtime interfaces');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.abi = abi instanceof Abi
|
||||||
|
? abi
|
||||||
|
: new Abi(abi, api.registry.getChainProperties());
|
||||||
|
this.api = api;
|
||||||
|
this._decorateMethod = decorateMethod;
|
||||||
|
this._isOldWeight = isFunction(api.registry.createType<INumber>('Weight').toBn);
|
||||||
}
|
}
|
||||||
|
|
||||||
public get registry (): Registry {
|
public get registry (): Registry {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import type { SubmittableExtrinsic } from '@polkadot/api/submittable/types';
|
|||||||
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
||||||
import type { AccountId, EventRecord, Hash } from '@polkadot/types/interfaces';
|
import type { AccountId, EventRecord, Hash } from '@polkadot/types/interfaces';
|
||||||
import type { ISubmittableResult } from '@polkadot/types/types';
|
import type { ISubmittableResult } from '@polkadot/types/types';
|
||||||
import type { AbiConstructor, BlueprintOptions } from '../types';
|
import type { AbiConstructor, BlueprintOptions, WeightAll } from '../types';
|
||||||
import type { MapConstructorExec } from './types';
|
import type { MapConstructorExec } from './types';
|
||||||
|
|
||||||
import { SubmittableResult } from '@polkadot/api';
|
import { SubmittableResult } from '@polkadot/api';
|
||||||
@@ -16,7 +16,7 @@ import { Abi } from '../Abi';
|
|||||||
import { applyOnEvent } from '../util';
|
import { applyOnEvent } from '../util';
|
||||||
import { Base } from './Base';
|
import { Base } from './Base';
|
||||||
import { Contract } from './Contract';
|
import { Contract } from './Contract';
|
||||||
import { createBluePrintTx, encodeSalt } from './util';
|
import { convertWeight, createBluePrintTx, encodeSalt } from './util';
|
||||||
|
|
||||||
export interface BlueprintConstructor<ApiType extends ApiTypes> {
|
export interface BlueprintConstructor<ApiType extends ApiTypes> {
|
||||||
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, codeHash: string | Hash | Uint8Array): Blueprint<ApiType>;
|
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, codeHash: string | Hash | Uint8Array): Blueprint<ApiType>;
|
||||||
@@ -57,16 +57,21 @@ export class Blueprint<ApiType extends ApiTypes> extends Base<ApiType> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#deploy = (constructorOrId: AbiConstructor | string | number, { gasLimit = BN_ZERO, salt, storageDepositLimit = null, value = BN_ZERO }: BlueprintOptions, params: unknown[]): SubmittableExtrinsic<ApiType, BlueprintSubmittableResult<ApiType>> => {
|
#deploy = (constructorOrId: AbiConstructor | string | number, { gasLimit = BN_ZERO, salt, storageDepositLimit = null, value = BN_ZERO }: BlueprintOptions, params: unknown[]): SubmittableExtrinsic<ApiType, BlueprintSubmittableResult<ApiType>> => {
|
||||||
const encParams = this.abi.findConstructor(constructorOrId).toU8a(params);
|
return this.api.tx.contracts.instantiate(
|
||||||
const encSalt = encodeSalt(salt);
|
value,
|
||||||
|
this._isOldWeight
|
||||||
return this.api.tx.contracts
|
// jiggle v1 weights, metadata points to latest
|
||||||
.instantiate(value, gasLimit, storageDepositLimit, this.codeHash, encParams, encSalt)
|
? convertWeight(gasLimit).v1Weight as unknown as WeightAll['v2Weight']
|
||||||
.withResultTransform((result: ISubmittableResult) =>
|
: convertWeight(gasLimit).v2Weight,
|
||||||
new BlueprintSubmittableResult(result, applyOnEvent(result, ['Instantiated'], ([record]: EventRecord[]) =>
|
storageDepositLimit,
|
||||||
new Contract<ApiType>(this.api, this.abi, record.event.data[1] as AccountId, this._decorateMethod)
|
this.codeHash,
|
||||||
))
|
this.abi.findConstructor(constructorOrId).toU8a(params),
|
||||||
);
|
encodeSalt(salt)
|
||||||
|
).withResultTransform((result: ISubmittableResult) =>
|
||||||
|
new BlueprintSubmittableResult(result, applyOnEvent(result, ['Instantiated'], ([record]: EventRecord[]) =>
|
||||||
|
new Contract<ApiType>(this.api, this.abi, record.event.data[1] as AccountId, this._decorateMethod)
|
||||||
|
))
|
||||||
|
);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
|||||||
import type { AccountId, EventRecord } from '@polkadot/types/interfaces';
|
import type { AccountId, EventRecord } from '@polkadot/types/interfaces';
|
||||||
import type { ISubmittableResult } from '@polkadot/types/types';
|
import type { ISubmittableResult } from '@polkadot/types/types';
|
||||||
import type { Codec } from '@polkadot/types-codec/types';
|
import type { Codec } from '@polkadot/types-codec/types';
|
||||||
import type { AbiConstructor, BlueprintOptions } from '../types';
|
import type { AbiConstructor, BlueprintOptions, WeightAll } from '../types';
|
||||||
import type { MapConstructorExec } from './types';
|
import type { MapConstructorExec } from './types';
|
||||||
|
|
||||||
import { SubmittableResult } from '@polkadot/api';
|
import { SubmittableResult } from '@polkadot/api';
|
||||||
@@ -18,7 +18,7 @@ import { applyOnEvent } from '../util';
|
|||||||
import { Base } from './Base';
|
import { Base } from './Base';
|
||||||
import { Blueprint } from './Blueprint';
|
import { Blueprint } from './Blueprint';
|
||||||
import { Contract } from './Contract';
|
import { Contract } from './Contract';
|
||||||
import { createBluePrintTx, encodeSalt } from './util';
|
import { convertWeight, createBluePrintTx, encodeSalt } from './util';
|
||||||
|
|
||||||
export interface CodeConstructor<ApiType extends ApiTypes> {
|
export interface CodeConstructor<ApiType extends ApiTypes> {
|
||||||
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, wasm: Uint8Array | string | Buffer | null | undefined): Code<ApiType>;
|
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, wasm: Uint8Array | string | Buffer | null | undefined): Code<ApiType>;
|
||||||
@@ -64,23 +64,27 @@ export class Code<ApiType extends ApiTypes> extends Base<ApiType> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#instantiate = (constructorOrId: AbiConstructor | string | number, { gasLimit = BN_ZERO, salt, storageDepositLimit = null, value = BN_ZERO }: BlueprintOptions, params: unknown[]): SubmittableExtrinsic<ApiType, CodeSubmittableResult<ApiType>> => {
|
#instantiate = (constructorOrId: AbiConstructor | string | number, { gasLimit = BN_ZERO, salt, storageDepositLimit = null, value = BN_ZERO }: BlueprintOptions, params: unknown[]): SubmittableExtrinsic<ApiType, CodeSubmittableResult<ApiType>> => {
|
||||||
const encCode = compactAddLength(this.code);
|
return this.api.tx.contracts.instantiateWithCode(
|
||||||
const encParams = this.abi.findConstructor(constructorOrId).toU8a(params);
|
value,
|
||||||
const encSalt = encodeSalt(salt);
|
this._isOldWeight
|
||||||
|
// jiggle v1 weights, metadata points to latest
|
||||||
return this.api.tx.contracts
|
? convertWeight(gasLimit).v1Weight as unknown as WeightAll['v2Weight']
|
||||||
.instantiateWithCode(value, gasLimit, storageDepositLimit, encCode, encParams, encSalt)
|
: convertWeight(gasLimit).v2Weight,
|
||||||
.withResultTransform((result: ISubmittableResult) =>
|
storageDepositLimit,
|
||||||
new CodeSubmittableResult(result, ...(applyOnEvent(result, ['CodeStored', 'Instantiated'], (records: EventRecord[]) =>
|
compactAddLength(this.code),
|
||||||
records.reduce<[Blueprint<ApiType>?, Contract<ApiType>?]>(([blueprint, contract], { event }) =>
|
this.abi.findConstructor(constructorOrId).toU8a(params),
|
||||||
this.api.events.contracts.Instantiated.is(event)
|
encodeSalt(salt)
|
||||||
? [blueprint, new Contract<ApiType>(this.api, this.abi, (event as unknown as { data: [Codec, AccountId] }).data[1], this._decorateMethod)]
|
).withResultTransform((result: ISubmittableResult) =>
|
||||||
: this.api.events.contracts.CodeStored.is(event)
|
new CodeSubmittableResult(result, ...(applyOnEvent(result, ['CodeStored', 'Instantiated'], (records: EventRecord[]) =>
|
||||||
? [new Blueprint<ApiType>(this.api, this.abi, (event as unknown as { data: [AccountId] }).data[0], this._decorateMethod), contract]
|
records.reduce<[Blueprint<ApiType>?, Contract<ApiType>?]>(([blueprint, contract], { event }) =>
|
||||||
: [blueprint, contract],
|
this.api.events.contracts.Instantiated.is(event)
|
||||||
[])
|
? [blueprint, new Contract<ApiType>(this.api, this.abi, (event as unknown as { data: [Codec, AccountId] }).data[1], this._decorateMethod)]
|
||||||
) || []))
|
: this.api.events.contracts.CodeStored.is(event)
|
||||||
);
|
? [new Blueprint<ApiType>(this.api, this.abi, (event as unknown as { data: [AccountId] }).data[0], this._decorateMethod), contract]
|
||||||
|
: [blueprint, contract],
|
||||||
|
[])
|
||||||
|
) || []))
|
||||||
|
);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,21 +4,21 @@
|
|||||||
import type { SubmittableExtrinsic } from '@polkadot/api/submittable/types';
|
import type { SubmittableExtrinsic } from '@polkadot/api/submittable/types';
|
||||||
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
import type { ApiTypes, DecorateMethod } from '@polkadot/api/types';
|
||||||
import type { Bytes } from '@polkadot/types';
|
import type { Bytes } from '@polkadot/types';
|
||||||
import type { AccountId, ContractExecResult, EventRecord, Weight } from '@polkadot/types/interfaces';
|
import type { AccountId, ContractExecResult, EventRecord, Weight, WeightV2 } from '@polkadot/types/interfaces';
|
||||||
import type { ISubmittableResult } from '@polkadot/types/types';
|
import type { ISubmittableResult } from '@polkadot/types/types';
|
||||||
import type { AbiMessage, ContractCallOutcome, ContractOptions, DecodedEvent } from '../types';
|
import type { AbiMessage, ContractCallOutcome, ContractOptions, DecodedEvent, WeightAll } from '../types';
|
||||||
import type { ContractCallResult, ContractCallSend, ContractQuery, ContractTx, MapMessageQuery, MapMessageTx } from './types';
|
import type { ContractCallResult, ContractCallSend, ContractQuery, ContractTx, MapMessageQuery, MapMessageTx } from './types';
|
||||||
|
|
||||||
import { map } from 'rxjs';
|
import { map } from 'rxjs';
|
||||||
|
|
||||||
import { SubmittableResult } from '@polkadot/api';
|
import { SubmittableResult } from '@polkadot/api';
|
||||||
import { ApiBase } from '@polkadot/api/base';
|
import { ApiBase } from '@polkadot/api/base';
|
||||||
import { BN, BN_HUNDRED, BN_ONE, BN_ZERO, bnToBn, isUndefined, logger } from '@polkadot/util';
|
import { BN, BN_HUNDRED, BN_ONE, BN_ZERO, isUndefined, logger } from '@polkadot/util';
|
||||||
|
|
||||||
import { Abi } from '../Abi';
|
import { Abi } from '../Abi';
|
||||||
import { applyOnEvent } from '../util';
|
import { applyOnEvent } from '../util';
|
||||||
import { Base } from './Base';
|
import { Base } from './Base';
|
||||||
import { withMeta } from './util';
|
import { convertWeight, withMeta } from './util';
|
||||||
|
|
||||||
export interface ContractConstructor<ApiType extends ApiTypes> {
|
export interface ContractConstructor<ApiType extends ApiTypes> {
|
||||||
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, address: string | AccountId): Contract<ApiType>;
|
new(api: ApiBase<ApiType>, abi: string | Record<string, unknown> | Abi, address: string | AccountId): Contract<ApiType>;
|
||||||
@@ -85,41 +85,50 @@ export class Contract<ApiType extends ApiTypes> extends Base<ApiType> {
|
|||||||
return this.#tx;
|
return this.#tx;
|
||||||
}
|
}
|
||||||
|
|
||||||
#getGas = (_gasLimit: bigint | BN | string | number, isCall = false): BN => {
|
#getGas = (_gasLimit: bigint | BN | string | number | WeightV2, isCall = false): WeightAll => {
|
||||||
const gasLimit = bnToBn(_gasLimit);
|
const weight = convertWeight(_gasLimit);
|
||||||
|
|
||||||
return gasLimit.lte(BN_ZERO)
|
if (weight.v1Weight.gt(BN_ZERO)) {
|
||||||
? isCall
|
return weight;
|
||||||
|
}
|
||||||
|
|
||||||
|
return convertWeight(
|
||||||
|
isCall
|
||||||
? MAX_CALL_GAS
|
? MAX_CALL_GAS
|
||||||
: (this.api.consts.system.blockWeights
|
: convertWeight(
|
||||||
? (this.api.consts.system.blockWeights as unknown as { maxBlock: Weight }).maxBlock
|
this.api.consts.system.blockWeights
|
||||||
: this.api.consts.system.maximumBlockWeight as Weight
|
? (this.api.consts.system.blockWeights as unknown as { maxBlock: WeightV2 }).maxBlock
|
||||||
).muln(64).div(BN_HUNDRED)
|
: this.api.consts.system.maximumBlockWeight as Weight
|
||||||
: gasLimit;
|
).v1Weight.muln(64).div(BN_HUNDRED)
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
#exec = (messageOrId: AbiMessage | string | number, { gasLimit = BN_ZERO, storageDepositLimit = null, value = BN_ZERO }: ContractOptions, params: unknown[]): SubmittableExtrinsic<ApiType> => {
|
#exec = (messageOrId: AbiMessage | string | number, { gasLimit = BN_ZERO, storageDepositLimit = null, value = BN_ZERO }: ContractOptions, params: unknown[]): SubmittableExtrinsic<ApiType> => {
|
||||||
const gas = this.#getGas(gasLimit);
|
return this.api.tx.contracts.call(
|
||||||
const encParams = this.abi.findMessage(messageOrId).toU8a(params);
|
this.address,
|
||||||
|
value,
|
||||||
|
this._isOldWeight
|
||||||
|
// jiggle v1 weights, metadata points to latest
|
||||||
|
? convertWeight(gasLimit).v1Weight as unknown as WeightAll['v2Weight']
|
||||||
|
: convertWeight(gasLimit).v2Weight,
|
||||||
|
storageDepositLimit,
|
||||||
|
this.abi.findMessage(messageOrId).toU8a(params)
|
||||||
|
).withResultTransform((result: ISubmittableResult) =>
|
||||||
|
// ContractEmitted is the current generation, ContractExecution is the previous generation
|
||||||
|
new ContractSubmittableResult(result, applyOnEvent(result, ['ContractEmitted', 'ContractExecution'], (records: EventRecord[]) =>
|
||||||
|
records
|
||||||
|
.map(({ event: { data: [, data] } }): DecodedEvent | null => {
|
||||||
|
try {
|
||||||
|
return this.abi.decodeEvent(data as Bytes);
|
||||||
|
} catch (error) {
|
||||||
|
l.error(`Unable to decode contract event: ${(error as Error).message}`);
|
||||||
|
|
||||||
return this.api.tx.contracts
|
return null;
|
||||||
.call(this.address, value, gas, storageDepositLimit, encParams)
|
}
|
||||||
.withResultTransform((result: ISubmittableResult) =>
|
})
|
||||||
// ContractEmitted is the current generation, ContractExecution is the previous generation
|
.filter((decoded): decoded is DecodedEvent => !!decoded)
|
||||||
new ContractSubmittableResult(result, applyOnEvent(result, ['ContractEmitted', 'ContractExecution'], (records: EventRecord[]) =>
|
))
|
||||||
records
|
);
|
||||||
.map(({ event: { data: [, data] } }): DecodedEvent | null => {
|
|
||||||
try {
|
|
||||||
return this.abi.decodeEvent(data as Bytes);
|
|
||||||
} catch (error) {
|
|
||||||
l.error(`Unable to decode contract event: ${(error as Error).message}`);
|
|
||||||
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.filter((decoded): decoded is DecodedEvent => !!decoded)
|
|
||||||
))
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#read = (messageOrId: AbiMessage | string | number, { gasLimit = BN_ZERO, storageDepositLimit = null, value = BN_ZERO }: ContractOptions, params: unknown[]): ContractCallSend<ApiType> => {
|
#read = (messageOrId: AbiMessage | string | number, { gasLimit = BN_ZERO, storageDepositLimit = null, value = BN_ZERO }: ContractOptions, params: unknown[]): ContractCallSend<ApiType> => {
|
||||||
@@ -128,22 +137,28 @@ export class Contract<ApiType extends ApiTypes> extends Base<ApiType> {
|
|||||||
return {
|
return {
|
||||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
||||||
send: this._decorateMethod((origin: string | AccountId | Uint8Array) =>
|
send: this._decorateMethod((origin: string | AccountId | Uint8Array) =>
|
||||||
this.api.rx.call.contractsApi
|
this.api.rx.call.contractsApi.call<ContractExecResult>(
|
||||||
.call<ContractExecResult>(origin, this.address, value, this.#getGas(gasLimit, true), storageDepositLimit, message.toU8a(params))
|
origin,
|
||||||
.pipe(
|
this.address,
|
||||||
map(({ debugMessage, gasConsumed, gasRequired, result, storageDeposit }): ContractCallOutcome => ({
|
value,
|
||||||
debugMessage,
|
// the runtime interface still used u64 inputs
|
||||||
gasConsumed,
|
this.#getGas(gasLimit, true).v1Weight,
|
||||||
gasRequired: gasRequired && !gasRequired.isZero()
|
storageDepositLimit,
|
||||||
? gasRequired
|
message.toU8a(params)
|
||||||
: gasConsumed,
|
).pipe(
|
||||||
output: result.isOk && message.returnType
|
map(({ debugMessage, gasConsumed, gasRequired, result, storageDeposit }): ContractCallOutcome => ({
|
||||||
? this.abi.registry.createTypeUnsafe(message.returnType.lookupName || message.returnType.type, [result.asOk.data.toU8a(true)], { isPedantic: true })
|
debugMessage,
|
||||||
: null,
|
gasConsumed,
|
||||||
result,
|
gasRequired: gasRequired && !gasRequired.isZero()
|
||||||
storageDeposit
|
? gasRequired
|
||||||
}))
|
: gasConsumed,
|
||||||
)
|
output: result.isOk && message.returnType
|
||||||
|
? this.abi.registry.createTypeUnsafe(message.returnType.lookupName || message.returnType.type, [result.asOk.data.toU8a(true)], { isPedantic: true })
|
||||||
|
: null,
|
||||||
|
result,
|
||||||
|
storageDeposit
|
||||||
|
}))
|
||||||
|
)
|
||||||
)
|
)
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -4,11 +4,13 @@
|
|||||||
import type { SubmittableResult } from '@polkadot/api';
|
import type { SubmittableResult } from '@polkadot/api';
|
||||||
import type { SubmittableExtrinsic } from '@polkadot/api/submittable/types';
|
import type { SubmittableExtrinsic } from '@polkadot/api/submittable/types';
|
||||||
import type { ApiTypes } from '@polkadot/api/types';
|
import type { ApiTypes } from '@polkadot/api/types';
|
||||||
import type { AbiConstructor, AbiMessage, BlueprintOptions } from '../types';
|
import type { WeightV1, WeightV2 } from '@polkadot/types/interfaces';
|
||||||
|
import type { BN } from '@polkadot/util';
|
||||||
|
import type { AbiConstructor, AbiMessage, BlueprintOptions, WeightAll } from '../types';
|
||||||
import type { BlueprintDeploy, ContractGeneric } from './types';
|
import type { BlueprintDeploy, ContractGeneric } from './types';
|
||||||
|
|
||||||
import { Bytes } from '@polkadot/types';
|
import { Bytes } from '@polkadot/types';
|
||||||
import { compactAddLength, u8aToU8a } from '@polkadot/util';
|
import { bnToBn, compactAddLength, u8aToU8a } from '@polkadot/util';
|
||||||
import { randomAsU8a } from '@polkadot/util-crypto';
|
import { randomAsU8a } from '@polkadot/util-crypto';
|
||||||
|
|
||||||
export const EMPTY_SALT = new Uint8Array();
|
export const EMPTY_SALT = new Uint8Array();
|
||||||
@@ -37,3 +39,14 @@ export function encodeSalt (salt: Uint8Array | string | null = randomAsU8a()): U
|
|||||||
? compactAddLength(u8aToU8a(salt))
|
? compactAddLength(u8aToU8a(salt))
|
||||||
: EMPTY_SALT;
|
: EMPTY_SALT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function convertWeight (orig: WeightV1 | WeightV2 | bigint | string | number | BN): WeightAll {
|
||||||
|
const refTime = (orig as WeightV2).proofSize
|
||||||
|
? (orig as WeightV2).refTime.toBn()
|
||||||
|
: bnToBn(orig as BN);
|
||||||
|
|
||||||
|
return {
|
||||||
|
v1Weight: refTime,
|
||||||
|
v2Weight: { refTime }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/api-contract', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/api-contract', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
import type { ApiBase } from '@polkadot/api/base';
|
import type { ApiBase } from '@polkadot/api/base';
|
||||||
import type { ApiTypes } from '@polkadot/api/types';
|
import type { ApiTypes } from '@polkadot/api/types';
|
||||||
import type { Text, u64 } from '@polkadot/types';
|
import type { Text, u64 } from '@polkadot/types';
|
||||||
import type { ContractExecResultResult, ContractSelector, StorageDeposit } from '@polkadot/types/interfaces';
|
import type { ContractExecResultResult, ContractSelector, StorageDeposit, WeightV2 } from '@polkadot/types/interfaces';
|
||||||
import type { Codec, TypeDef } from '@polkadot/types/types';
|
import type { Codec, TypeDef } from '@polkadot/types/types';
|
||||||
import type { BN } from '@polkadot/util';
|
import type { BN } from '@polkadot/util';
|
||||||
import type { Abi } from '.';
|
import type { Abi } from '.';
|
||||||
@@ -73,7 +73,7 @@ export interface DecodedMessage {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export interface ContractOptions {
|
export interface ContractOptions {
|
||||||
gasLimit?: bigint | string | number | BN;
|
gasLimit?: bigint | string | number | BN | WeightV2;
|
||||||
storageDepositLimit?: bigint | string | number | BN | null;
|
storageDepositLimit?: bigint | string | number | BN | null;
|
||||||
value?: bigint | BN | string | number;
|
value?: bigint | BN | string | number;
|
||||||
}
|
}
|
||||||
@@ -81,3 +81,10 @@ export interface ContractOptions {
|
|||||||
export interface BlueprintOptions extends ContractOptions {
|
export interface BlueprintOptions extends ContractOptions {
|
||||||
salt?: Uint8Array | string | null;
|
salt?: Uint8Array | string | null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface WeightAll {
|
||||||
|
v1Weight: BN;
|
||||||
|
v2Weight: {
|
||||||
|
refTime: BN;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|||||||
@@ -20,25 +20,25 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/api": "9.4.1",
|
"@polkadot/api": "9.6.1",
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/api-base": "9.4.1",
|
"@polkadot/api-base": "9.6.1",
|
||||||
"@polkadot/rpc-core": "9.4.1",
|
"@polkadot/rpc-core": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/util-crypto": "^10.1.8",
|
"@polkadot/util-crypto": "^10.1.11",
|
||||||
"rxjs": "^7.5.6"
|
"rxjs": "^7.5.7"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/api": "9.4.1",
|
"@polkadot/api": "9.6.1",
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/rpc-augment": "9.4.1",
|
"@polkadot/rpc-augment": "9.6.1",
|
||||||
"@polkadot/rpc-provider": "9.4.1",
|
"@polkadot/rpc-provider": "9.6.1",
|
||||||
"@polkadot/types-support": "9.4.1"
|
"@polkadot/types-support": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import { map, of, switchMap } from 'rxjs';
|
|||||||
import { BN_ZERO, bnToBn, objectSpread } from '@polkadot/util';
|
import { BN_ZERO, bnToBn, objectSpread } from '@polkadot/util';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
|
import { getQueryInterface } from './util';
|
||||||
|
|
||||||
function orderBags (ids: BN[], bags: Option<PalletBagsListListBag>[]): Bag[] {
|
function orderBags (ids: BN[], bags: Option<PalletBagsListListBag>[]): Bag[] {
|
||||||
const sorted = ids
|
const sorted = ids
|
||||||
@@ -36,11 +37,13 @@ function orderBags (ids: BN[], bags: Option<PalletBagsListListBag>[]): Bag[] {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function _getIds (instanceId: string, api: DeriveApi): (ids: (BN | number)[]) => Observable<Bag[]> {
|
export function _getIds (instanceId: string, api: DeriveApi): (ids: (BN | number)[]) => Observable<Bag[]> {
|
||||||
|
const query = getQueryInterface(api);
|
||||||
|
|
||||||
return memo(instanceId, (_ids: (BN | number)[]): Observable<Bag[]> => {
|
return memo(instanceId, (_ids: (BN | number)[]): Observable<Bag[]> => {
|
||||||
const ids = _ids.map((id) => bnToBn(id));
|
const ids = _ids.map((id) => bnToBn(id));
|
||||||
|
|
||||||
return ids.length
|
return ids.length
|
||||||
? (api.query.voterList || api.query.bagsList).listBags.multi<Option<PalletBagsListListBag>>(ids).pipe(
|
? query.listBags.multi<Option<PalletBagsListListBag>>(ids).pipe(
|
||||||
map((bags) => orderBags(ids, bags))
|
map((bags) => orderBags(ids, bags))
|
||||||
)
|
)
|
||||||
: of([]);
|
: of([]);
|
||||||
@@ -48,8 +51,10 @@ export function _getIds (instanceId: string, api: DeriveApi): (ids: (BN | number
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function all (instanceId: string, api: DeriveApi): () => Observable<Bag[]> {
|
export function all (instanceId: string, api: DeriveApi): () => Observable<Bag[]> {
|
||||||
|
const query = getQueryInterface(api);
|
||||||
|
|
||||||
return memo(instanceId, (): Observable<Bag[]> =>
|
return memo(instanceId, (): Observable<Bag[]> =>
|
||||||
(api.query.voterList || api.query.bagsList).listBags.keys<[u64]>().pipe(
|
query.listBags.keys<[u64]>().pipe(
|
||||||
switchMap((keys) =>
|
switchMap((keys) =>
|
||||||
api.derive.bagsList._getIds(keys.map(({ args: [id] }) => id))
|
api.derive.bagsList._getIds(keys.map(({ args: [id] }) => id))
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -12,13 +12,15 @@ import { BehaviorSubject, map, of, switchMap, tap, toArray } from 'rxjs';
|
|||||||
import { nextTick } from '@polkadot/util';
|
import { nextTick } from '@polkadot/util';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
|
import { getQueryInterface } from './util';
|
||||||
|
|
||||||
function traverseLinks (api: DeriveApi, head: AccountId32 | string): Observable<PalletBagsListListNode[]> {
|
function traverseLinks (api: DeriveApi, head: AccountId32 | string): Observable<PalletBagsListListNode[]> {
|
||||||
const subject = new BehaviorSubject<AccountId32 | string>(head);
|
const subject = new BehaviorSubject<AccountId32 | string>(head);
|
||||||
|
const query = getQueryInterface(api);
|
||||||
|
|
||||||
return subject.pipe(
|
return subject.pipe(
|
||||||
switchMap((account) =>
|
switchMap((account) =>
|
||||||
(api.query.voterList || api.query.bagsList).listNodes<Option<PalletBagsListListNode>>(account)
|
query.listNodes<Option<PalletBagsListListNode>>(account)
|
||||||
),
|
),
|
||||||
tap((node: Option<PalletBagsListListNode>): void => {
|
tap((node: Option<PalletBagsListListNode>): void => {
|
||||||
nextTick((): void => {
|
nextTick((): void => {
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
// Copyright 2017-2022 @polkadot/api-derive authors & contributors
|
||||||
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
|
import type { QueryableStorage } from '@polkadot/api-base/types';
|
||||||
|
import type { DeriveApi } from '../types';
|
||||||
|
|
||||||
|
export function getQueryInterface (api: DeriveApi): QueryableStorage<'rxjs'>['voterBagsList'] {
|
||||||
|
return (
|
||||||
|
// latest substrate (latest always first)
|
||||||
|
api.query.voterBagsList ||
|
||||||
|
// previous substrate
|
||||||
|
api.query.bagsList ||
|
||||||
|
// latest polkadot
|
||||||
|
api.query.voterList
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -27,7 +27,7 @@ const checks: Record<string, Avail> = {
|
|||||||
methods: []
|
methods: []
|
||||||
},
|
},
|
||||||
bagsList: {
|
bagsList: {
|
||||||
instances: ['voterList', 'bagsList'],
|
instances: ['voterBagsList', 'voterList', 'bagsList'],
|
||||||
methods: [],
|
methods: [],
|
||||||
withDetect: true
|
withDetect: true
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -4,8 +4,9 @@
|
|||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { Option, Vec } from '@polkadot/types';
|
import type { Option, Vec } from '@polkadot/types';
|
||||||
import type { BlockNumber, Call, Hash, ReferendumIndex, Scheduled } from '@polkadot/types/interfaces';
|
import type { BlockNumber, Call, Hash, ReferendumIndex, Scheduled } from '@polkadot/types/interfaces';
|
||||||
import type { FrameSupportScheduleMaybeHashed, PalletSchedulerScheduledV3 } from '@polkadot/types/lookup';
|
import type { FrameSupportPreimagesBounded, FrameSupportScheduleMaybeHashed, PalletSchedulerScheduled, PalletSchedulerScheduledV3 } from '@polkadot/types/lookup';
|
||||||
import type { ITuple } from '@polkadot/types/types';
|
import type { ITuple } from '@polkadot/types/types';
|
||||||
|
import type { HexString } from '@polkadot/util/types';
|
||||||
import type { DeriveApi, DeriveDispatch, DeriveProposalImage } from '../types';
|
import type { DeriveApi, DeriveDispatch, DeriveProposalImage } from '../types';
|
||||||
|
|
||||||
import { catchError, combineLatest, map, of, switchMap } from 'rxjs';
|
import { catchError, combineLatest, map, of, switchMap } from 'rxjs';
|
||||||
@@ -14,20 +15,26 @@ import { Enum } from '@polkadot/types';
|
|||||||
import { isFunction, objectSpread, stringToHex } from '@polkadot/util';
|
import { isFunction, objectSpread, stringToHex } from '@polkadot/util';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
|
import { getImageHashBounded } from './util';
|
||||||
|
|
||||||
const DEMOCRACY_ID = stringToHex('democrac');
|
const DEMOCRACY_ID = stringToHex('democrac');
|
||||||
|
|
||||||
interface SchedulerInfo {
|
interface SchedulerInfo {
|
||||||
at: BlockNumber;
|
at: BlockNumber;
|
||||||
imageHash: Hash;
|
imageHash: HexString;
|
||||||
index: ReferendumIndex;
|
index: ReferendumIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
function isMaybeHashed (call: FrameSupportScheduleMaybeHashed | Call): call is FrameSupportScheduleMaybeHashed {
|
function isMaybeHashedOrBounded (call: FrameSupportPreimagesBounded | FrameSupportScheduleMaybeHashed | Call): call is FrameSupportScheduleMaybeHashed | FrameSupportPreimagesBounded {
|
||||||
// check for enum
|
// check for enum
|
||||||
return call instanceof Enum;
|
return call instanceof Enum;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function isBounded (call: FrameSupportPreimagesBounded | FrameSupportScheduleMaybeHashed): call is FrameSupportPreimagesBounded {
|
||||||
|
// check for type
|
||||||
|
return (call as FrameSupportPreimagesBounded).isInline || (call as FrameSupportPreimagesBounded).isLegacy || (call as FrameSupportPreimagesBounded).isLookup;
|
||||||
|
}
|
||||||
|
|
||||||
function queryQueue (api: DeriveApi): Observable<DeriveDispatch[]> {
|
function queryQueue (api: DeriveApi): Observable<DeriveDispatch[]> {
|
||||||
return api.query.democracy.dispatchQueue<Vec<ITuple<[BlockNumber, Hash, ReferendumIndex]>>>().pipe(
|
return api.query.democracy.dispatchQueue<Vec<ITuple<[BlockNumber, Hash, ReferendumIndex]>>>().pipe(
|
||||||
switchMap((dispatches) =>
|
switchMap((dispatches) =>
|
||||||
@@ -41,14 +48,14 @@ function queryQueue (api: DeriveApi): Observable<DeriveDispatch[]> {
|
|||||||
dispatches.map(([at, imageHash, index], dispatchIndex): DeriveDispatch => ({
|
dispatches.map(([at, imageHash, index], dispatchIndex): DeriveDispatch => ({
|
||||||
at,
|
at,
|
||||||
image: images[dispatchIndex],
|
image: images[dispatchIndex],
|
||||||
imageHash,
|
imageHash: getImageHashBounded(imageHash),
|
||||||
index
|
index
|
||||||
}))
|
}))
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
function schedulerEntries (api: DeriveApi): Observable<[BlockNumber[], Option<PalletSchedulerScheduledV3 | Scheduled>[][]]> {
|
function schedulerEntries (api: DeriveApi): Observable<[BlockNumber[], Option<PalletSchedulerScheduled | PalletSchedulerScheduledV3 | Scheduled>[][]]> {
|
||||||
// We don't get entries, but rather we get the keys (triggered via finished referendums) and
|
// We don't get entries, but rather we get the keys (triggered via finished referendums) and
|
||||||
// the subscribe to those keys - this means we pickup when the schedulers actually executes
|
// the subscribe to those keys - this means we pickup when the schedulers actually executes
|
||||||
// at a block, the entry for that block will become empty
|
// at a block, the entry for that block will become empty
|
||||||
@@ -87,11 +94,13 @@ function queryScheduler (api: DeriveApi): Observable<DeriveDispatch[]> {
|
|||||||
const id = scheduled.maybeId.unwrap().toHex();
|
const id = scheduled.maybeId.unwrap().toHex();
|
||||||
|
|
||||||
if (id.startsWith(DEMOCRACY_ID)) {
|
if (id.startsWith(DEMOCRACY_ID)) {
|
||||||
const imageHash = isMaybeHashed(scheduled.call)
|
const imageHash = isMaybeHashedOrBounded(scheduled.call)
|
||||||
? scheduled.call.isHash
|
? isBounded(scheduled.call)
|
||||||
? scheduled.call.asHash
|
? getImageHashBounded(scheduled.call)
|
||||||
: scheduled.call.asValue.args[0] as Hash
|
: scheduled.call.isHash
|
||||||
: scheduled.call.args[0] as Hash;
|
? scheduled.call.asHash.toHex()
|
||||||
|
: scheduled.call.asValue.args[0].toHex()
|
||||||
|
: scheduled.call.args[0].toHex();
|
||||||
|
|
||||||
result.push({ at, imageHash, index: api.registry.createType('(u64, ReferendumIndex)', id)[1] });
|
result.push({ at, imageHash, index: api.registry.createType('(u64, ReferendumIndex)', id)[1] });
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,25 +4,26 @@
|
|||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { Option } from '@polkadot/types';
|
import type { Option } from '@polkadot/types';
|
||||||
import type { H256 } from '@polkadot/types/interfaces';
|
import type { H256 } from '@polkadot/types/interfaces';
|
||||||
import type { PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
import type { FrameSupportPreimagesBounded, PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
||||||
import type { ITuple } from '@polkadot/types/types';
|
import type { ITuple } from '@polkadot/types/types';
|
||||||
import type { DeriveApi, DeriveProposalExternal } from '../types';
|
import type { DeriveApi, DeriveProposalExternal } from '../types';
|
||||||
|
|
||||||
import { map, of, switchMap } from 'rxjs';
|
import { map, of, switchMap } from 'rxjs';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
|
import { getImageHashBounded } from './util';
|
||||||
|
|
||||||
function withImage (api: DeriveApi, nextOpt: Option<ITuple<[H256, PalletDemocracyVoteThreshold]>>): Observable<DeriveProposalExternal | null> {
|
function withImage (api: DeriveApi, nextOpt: Option<ITuple<[H256 | FrameSupportPreimagesBounded, PalletDemocracyVoteThreshold]>>): Observable<DeriveProposalExternal | null> {
|
||||||
if (nextOpt.isNone) {
|
if (nextOpt.isNone) {
|
||||||
return of(null);
|
return of(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
const [imageHash, threshold] = nextOpt.unwrap();
|
const [hash, threshold] = nextOpt.unwrap();
|
||||||
|
|
||||||
return api.derive.democracy.preimage(imageHash).pipe(
|
return api.derive.democracy.preimage(hash).pipe(
|
||||||
map((image): DeriveProposalExternal => ({
|
map((image): DeriveProposalExternal => ({
|
||||||
image,
|
image,
|
||||||
imageHash,
|
imageHash: getImageHashBounded(hash),
|
||||||
threshold
|
threshold
|
||||||
}))
|
}))
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -2,16 +2,19 @@
|
|||||||
// SPDX-License-Identifier: Apache-2.0
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { AccountId, Balance, BlockNumber, Hash, PreimageStatus, Proposal } from '@polkadot/types/interfaces';
|
import type { AccountId, Balance, BlockNumber, Call, Hash, PreimageStatus } from '@polkadot/types/interfaces';
|
||||||
|
import type { FrameSupportPreimagesBounded, PalletPreimageRequestStatus } from '@polkadot/types/lookup';
|
||||||
import type { Bytes, Option } from '@polkadot/types-codec';
|
import type { Bytes, Option } from '@polkadot/types-codec';
|
||||||
import type { ITuple } from '@polkadot/types-codec/types';
|
import type { ITuple } from '@polkadot/types-codec/types';
|
||||||
|
import type { HexString } from '@polkadot/util/types';
|
||||||
import type { DeriveApi, DeriveProposalImage } from '../types';
|
import type { DeriveApi, DeriveProposalImage } from '../types';
|
||||||
|
|
||||||
import { map, of } from 'rxjs';
|
import { map, of, switchMap } from 'rxjs';
|
||||||
|
|
||||||
import { isFunction } from '@polkadot/util';
|
import { BN_ZERO, isFunction } from '@polkadot/util';
|
||||||
|
|
||||||
import { firstMemo, memo } from '../util';
|
import { firstMemo, memo } from '../util';
|
||||||
|
import { getImageHashBounded } from './util';
|
||||||
|
|
||||||
type PreimageInfo = [Bytes, AccountId, Balance, BlockNumber];
|
type PreimageInfo = [Bytes, AccountId, Balance, BlockNumber];
|
||||||
type OldPreimage = ITuple<PreimageInfo>;
|
type OldPreimage = ITuple<PreimageInfo>;
|
||||||
@@ -21,10 +24,10 @@ function isDemocracyPreimage (api: DeriveApi, imageOpt: Option<OldPreimage> | Op
|
|||||||
}
|
}
|
||||||
|
|
||||||
function constructProposal (api: DeriveApi, [bytes, proposer, balance, at]: PreimageInfo): DeriveProposalImage {
|
function constructProposal (api: DeriveApi, [bytes, proposer, balance, at]: PreimageInfo): DeriveProposalImage {
|
||||||
let proposal: Proposal | undefined;
|
let proposal: Call | undefined;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
proposal = api.registry.createType('Proposal', bytes.toU8a(true));
|
proposal = api.registry.createType('Call', bytes.toU8a(true));
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
}
|
}
|
||||||
@@ -52,25 +55,81 @@ function parseDemocracy (api: DeriveApi, imageOpt: Option<OldPreimage> | Option<
|
|||||||
return constructProposal(api, imageOpt.unwrap());
|
return constructProposal(api, imageOpt.unwrap());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function parseImage (api: DeriveApi, [proposalHash, status, bytes]: [HexString, PalletPreimageRequestStatus | null, Bytes | null]): DeriveProposalImage | undefined {
|
||||||
|
if (!status) {
|
||||||
|
return undefined;
|
||||||
|
}
|
||||||
|
|
||||||
|
const [proposer, balance] = status.isUnrequested
|
||||||
|
? status.asUnrequested.deposit
|
||||||
|
: status.asRequested.deposit.unwrapOrDefault();
|
||||||
|
let proposal: Call | undefined;
|
||||||
|
|
||||||
|
if (bytes) {
|
||||||
|
try {
|
||||||
|
proposal = api.registry.createType('Call', bytes.toU8a(true));
|
||||||
|
} catch (error) {
|
||||||
|
console.error(error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return { at: BN_ZERO, balance, proposal, proposalHash, proposer };
|
||||||
|
}
|
||||||
|
|
||||||
function getDemocracyImages (api: DeriveApi, hashes: (Hash | Uint8Array | string)[]): Observable<(DeriveProposalImage | undefined)[]> {
|
function getDemocracyImages (api: DeriveApi, hashes: (Hash | Uint8Array | string)[]): Observable<(DeriveProposalImage | undefined)[]> {
|
||||||
return api.query.democracy.preimages.multi(hashes).pipe(
|
return api.query.democracy.preimages.multi<Option<PreimageStatus>>(hashes).pipe(
|
||||||
map((images): (DeriveProposalImage | undefined)[] =>
|
map((images): (DeriveProposalImage | undefined)[] =>
|
||||||
images.map((imageOpt) => parseDemocracy(api, imageOpt))
|
images.map((imageOpt) => parseDemocracy(api, imageOpt))
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export function preimages (instanceId: string, api: DeriveApi): (hashes: (Hash | Uint8Array | string)[]) => Observable<(DeriveProposalImage | undefined)[]> {
|
function getImages (api: DeriveApi, bounded: FrameSupportPreimagesBounded[]): Observable<(DeriveProposalImage | undefined)[]> {
|
||||||
return memo(instanceId, (hashes: (Hash | Uint8Array | string)[]): Observable<(DeriveProposalImage | undefined)[]> =>
|
const hashes = bounded.map((b) => getImageHashBounded(b));
|
||||||
|
|
||||||
|
return api.query.preimage.statusFor.multi(hashes).pipe(
|
||||||
|
switchMap((optStatus) => {
|
||||||
|
const statuses = optStatus.map((o) => o.unwrapOr(null));
|
||||||
|
const keys = statuses
|
||||||
|
.map((s, i) =>
|
||||||
|
s
|
||||||
|
? s.isRequested
|
||||||
|
? [hashes[i], s.asRequested.len.unwrapOr(0)]
|
||||||
|
: [hashes[i], s.asUnrequested.len]
|
||||||
|
: null
|
||||||
|
)
|
||||||
|
.filter((p) => !!p);
|
||||||
|
|
||||||
|
return api.query.preimage.preimageFor.multi(keys).pipe(
|
||||||
|
map((optBytes) => {
|
||||||
|
let ptr = -1;
|
||||||
|
|
||||||
|
return statuses
|
||||||
|
.map((s, i): [HexString, PalletPreimageRequestStatus | null, Bytes | null] =>
|
||||||
|
s
|
||||||
|
? [hashes[i], s, optBytes[++ptr].unwrapOr(null)]
|
||||||
|
: [hashes[i], null, null]
|
||||||
|
)
|
||||||
|
.map((v) => parseImage(api, v));
|
||||||
|
})
|
||||||
|
);
|
||||||
|
})
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export function preimages (instanceId: string, api: DeriveApi): (hashes: (Hash | Uint8Array | string | FrameSupportPreimagesBounded)[]) => Observable<(DeriveProposalImage | undefined)[]> {
|
||||||
|
return memo(instanceId, (hashes: (Hash | Uint8Array | string | FrameSupportPreimagesBounded)[]): Observable<(DeriveProposalImage | undefined)[]> =>
|
||||||
hashes.length
|
hashes.length
|
||||||
? isFunction(api.query.democracy.preimages)
|
? isFunction(api.query.democracy.preimages)
|
||||||
? getDemocracyImages(api, hashes)
|
? getDemocracyImages(api, hashes as string[])
|
||||||
: of([])
|
: isFunction(api.query.preimage.preimageFor)
|
||||||
|
? getImages(api, hashes as FrameSupportPreimagesBounded[])
|
||||||
|
: of([])
|
||||||
: of([])
|
: of([])
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export const preimage = firstMemo(
|
export const preimage = firstMemo(
|
||||||
(api: DeriveApi, hash: Hash | Uint8Array | string) =>
|
(api: DeriveApi, hash: Hash | Uint8Array | string | FrameSupportPreimagesBounded) =>
|
||||||
api.derive.democracy.preimages([hash])
|
api.derive.democracy.preimages([hash])
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { Option, Vec } from '@polkadot/types';
|
import type { Option, Vec } from '@polkadot/types';
|
||||||
import type { AccountId, Balance, Hash, PropIndex } from '@polkadot/types/interfaces';
|
import type { AccountId, Balance, Hash, PropIndex } from '@polkadot/types/interfaces';
|
||||||
|
import type { FrameSupportPreimagesBounded } from '@polkadot/types/lookup';
|
||||||
import type { ITuple } from '@polkadot/types/types';
|
import type { ITuple } from '@polkadot/types/types';
|
||||||
import type { DeriveApi, DeriveProposal, DeriveProposalImage } from '../types';
|
import type { DeriveApi, DeriveProposal, DeriveProposalImage } from '../types';
|
||||||
|
|
||||||
@@ -12,11 +13,12 @@ import { combineLatest, map, of, switchMap } from 'rxjs';
|
|||||||
import { isFunction, objectSpread } from '@polkadot/util';
|
import { isFunction, objectSpread } from '@polkadot/util';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
|
import { getImageHashBounded } from './util';
|
||||||
|
|
||||||
type DepositorsNew = Option<ITuple<[Vec<AccountId>, Balance]>>;
|
type DepositorsNew = Option<ITuple<[Vec<AccountId>, Balance]>>;
|
||||||
type DepositorsOld = Option<ITuple<[Balance, Vec<AccountId>]>>;
|
type DepositorsOld = Option<ITuple<[Balance, Vec<AccountId>]>>;
|
||||||
type Depositors = DepositorsNew | DepositorsOld;
|
type Depositors = DepositorsNew | DepositorsOld;
|
||||||
type Proposals = ITuple<[PropIndex, Hash, AccountId]>[];
|
type Proposals = ITuple<[PropIndex, Hash | FrameSupportPreimagesBounded, AccountId]>[];
|
||||||
type Result = [Proposals, (DeriveProposalImage | undefined)[], Depositors[]];
|
type Result = [Proposals, (DeriveProposalImage | undefined)[], Depositors[]];
|
||||||
|
|
||||||
function isNewDepositors (depositors: ITuple<[Vec<AccountId>, Balance]> | ITuple<[Balance, Vec<AccountId>]>): depositors is ITuple<[Vec<AccountId>, Balance]> {
|
function isNewDepositors (depositors: ITuple<[Vec<AccountId>, Balance]> | ITuple<[Balance, Vec<AccountId>]>): depositors is ITuple<[Vec<AccountId>, Balance]> {
|
||||||
@@ -30,13 +32,13 @@ function parse ([proposals, images, optDepositors]: Result): DeriveProposal[] {
|
|||||||
.filter(([, , proposer], index): boolean =>
|
.filter(([, , proposer], index): boolean =>
|
||||||
!!(optDepositors[index]?.isSome) && !proposer.isEmpty
|
!!(optDepositors[index]?.isSome) && !proposer.isEmpty
|
||||||
)
|
)
|
||||||
.map(([index, imageHash, proposer], proposalIndex): DeriveProposal => {
|
.map(([index, hash, proposer], proposalIndex): DeriveProposal => {
|
||||||
const depositors = optDepositors[proposalIndex].unwrap();
|
const depositors = optDepositors[proposalIndex].unwrap();
|
||||||
|
|
||||||
return objectSpread(
|
return objectSpread(
|
||||||
{
|
{
|
||||||
image: images[proposalIndex],
|
image: images[proposalIndex],
|
||||||
imageHash,
|
imageHash: getImageHashBounded(hash),
|
||||||
index,
|
index,
|
||||||
proposer
|
proposer
|
||||||
},
|
},
|
||||||
@@ -56,7 +58,7 @@ export function proposals (instanceId: string, api: DeriveApi): () => Observable
|
|||||||
? combineLatest([
|
? combineLatest([
|
||||||
of(proposals),
|
of(proposals),
|
||||||
api.derive.democracy.preimages(
|
api.derive.democracy.preimages(
|
||||||
proposals.map(([, hash]) => hash)
|
proposals.map(([, hash]) => hash as unknown as Uint8Array)
|
||||||
),
|
),
|
||||||
api.query.democracy.depositOf.multi(
|
api.query.democracy.depositOf.multi(
|
||||||
proposals.map(([index]) => index)
|
proposals.map(([index]) => index)
|
||||||
|
|||||||
@@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { Option, Vec } from '@polkadot/types';
|
import type { Option, Vec } from '@polkadot/types';
|
||||||
import type { AccountId, ReferendumInfoTo239, Vote } from '@polkadot/types/interfaces';
|
import type { AccountId, Hash, ReferendumInfoTo239, Vote } from '@polkadot/types/interfaces';
|
||||||
import type { PalletDemocracyReferendumInfo, PalletDemocracyVoteVoting } from '@polkadot/types/lookup';
|
import type { PalletDemocracyReferendumInfo, PalletDemocracyReferendumStatus, PalletDemocracyVoteVoting } from '@polkadot/types/lookup';
|
||||||
import type { BN } from '@polkadot/util';
|
import type { BN } from '@polkadot/util';
|
||||||
import type { DeriveApi, DeriveBalancesAccount, DeriveReferendum, DeriveReferendumVote, DeriveReferendumVotes } from '../types';
|
import type { DeriveApi, DeriveBalancesAccount, DeriveReferendum, DeriveReferendumVote, DeriveReferendumVotes } from '../types';
|
||||||
|
|
||||||
@@ -13,7 +13,7 @@ import { combineLatest, map, of, switchMap } from 'rxjs';
|
|||||||
import { isFunction, objectSpread } from '@polkadot/util';
|
import { isFunction, objectSpread } from '@polkadot/util';
|
||||||
|
|
||||||
import { memo } from '../util';
|
import { memo } from '../util';
|
||||||
import { calcVotes, getStatus } from './util';
|
import { calcVotes, getImageHash, getStatus } from './util';
|
||||||
|
|
||||||
type VotingDelegating = PalletDemocracyVoteVoting['asDelegating'];
|
type VotingDelegating = PalletDemocracyVoteVoting['asDelegating'];
|
||||||
type VotingDirect = PalletDemocracyVoteVoting['asDirect'];
|
type VotingDirect = PalletDemocracyVoteVoting['asDirect'];
|
||||||
@@ -133,10 +133,13 @@ export function _referendumInfo (instanceId: string, api: DeriveApi): (index: BN
|
|||||||
const status = getStatus(info);
|
const status = getStatus(info);
|
||||||
|
|
||||||
return status
|
return status
|
||||||
? api.derive.democracy.preimage(status.proposalHash).pipe(
|
? api.derive.democracy.preimage(
|
||||||
|
(status as PalletDemocracyReferendumStatus).proposal ||
|
||||||
|
(status as unknown as { proposalHash: Hash }).proposalHash
|
||||||
|
).pipe(
|
||||||
map((image): DeriveReferendum => ({
|
map((image): DeriveReferendum => ({
|
||||||
image,
|
image,
|
||||||
imageHash: status.proposalHash,
|
imageHash: getImageHash(status),
|
||||||
index: api.registry.createType('ReferendumIndex', index),
|
index: api.registry.createType('ReferendumIndex', index),
|
||||||
status
|
status
|
||||||
}))
|
}))
|
||||||
@@ -157,7 +160,7 @@ export function referendumsInfo (instanceId: string, api: DeriveApi): (ids: BN[]
|
|||||||
)
|
)
|
||||||
),
|
),
|
||||||
map((infos) =>
|
map((infos) =>
|
||||||
infos.filter((referendum): referendum is DeriveReferendum => !!referendum)
|
infos.filter((r): r is DeriveReferendum => !!r)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
: of([])
|
: of([])
|
||||||
|
|||||||
@@ -2,12 +2,13 @@
|
|||||||
// SPDX-License-Identifier: Apache-2.0
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
import type { Vec } from '@polkadot/types';
|
import type { Vec } from '@polkadot/types';
|
||||||
import type { AccountId, Balance, BlockNumber, Hash, PropIndex, Proposal, ReferendumIndex, ReferendumInfoTo239, Vote } from '@polkadot/types/interfaces';
|
import type { AccountId, Balance, Call, Hash, PropIndex, ReferendumIndex, ReferendumInfoTo239, Vote } from '@polkadot/types/interfaces';
|
||||||
import type { PalletDemocracyReferendumStatus, PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
import type { PalletDemocracyReferendumStatus, PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
||||||
import type { BN } from '@polkadot/util';
|
import type { BN } from '@polkadot/util';
|
||||||
|
import type { HexString } from '@polkadot/util/types';
|
||||||
|
|
||||||
export interface AtBlock {
|
export interface AtBlock {
|
||||||
at: BlockNumber;
|
at: BN;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface DeriveDemocracyLock {
|
export interface DeriveDemocracyLock {
|
||||||
@@ -22,13 +23,15 @@ export interface DeriveDemocracyLock {
|
|||||||
|
|
||||||
export interface DeriveProposalImage extends AtBlock {
|
export interface DeriveProposalImage extends AtBlock {
|
||||||
balance: Balance;
|
balance: Balance;
|
||||||
proposal?: Proposal;
|
proposal?: Call;
|
||||||
|
proposalHash?: HexString;
|
||||||
|
proposalLen?: number;
|
||||||
proposer: AccountId;
|
proposer: AccountId;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface DeriveDispatch extends AtBlock {
|
export interface DeriveDispatch extends AtBlock {
|
||||||
index: ReferendumIndex;
|
index: ReferendumIndex;
|
||||||
imageHash: Hash;
|
imageHash: HexString;
|
||||||
image?: DeriveProposalImage;
|
image?: DeriveProposalImage;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -43,14 +46,14 @@ export interface DeriveProposal {
|
|||||||
|
|
||||||
export interface DeriveProposalExternal {
|
export interface DeriveProposalExternal {
|
||||||
image?: DeriveProposalImage;
|
image?: DeriveProposalImage;
|
||||||
imageHash: Hash;
|
imageHash: HexString;
|
||||||
threshold: PalletDemocracyVoteThreshold;
|
threshold: PalletDemocracyVoteThreshold;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface DeriveReferendum {
|
export interface DeriveReferendum {
|
||||||
index: ReferendumIndex;
|
index: ReferendumIndex;
|
||||||
image?: DeriveProposalImage;
|
image?: DeriveProposalImage;
|
||||||
imageHash: Hash;
|
imageHash: HexString;
|
||||||
status: PalletDemocracyReferendumStatus | ReferendumInfoTo239;
|
status: PalletDemocracyReferendumStatus | ReferendumInfoTo239;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,10 @@
|
|||||||
// Copyright 2017-2022 @polkadot/api-derive authors & contributors
|
// Copyright 2017-2022 @polkadot/api-derive authors & contributors
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
import type { ReferendumInfoTo239, Tally } from '@polkadot/types/interfaces';
|
import type { Hash, ReferendumInfoTo239, Tally } from '@polkadot/types/interfaces';
|
||||||
import type { PalletDemocracyReferendumInfo, PalletDemocracyReferendumStatus, PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
import type { FrameSupportPreimagesBounded, PalletDemocracyReferendumInfo, PalletDemocracyReferendumStatus, PalletDemocracyVoteThreshold } from '@polkadot/types/lookup';
|
||||||
import type { Option } from '@polkadot/types-codec';
|
import type { Option } from '@polkadot/types-codec';
|
||||||
|
import type { HexString } from '@polkadot/util/types';
|
||||||
import type { DeriveReferendum, DeriveReferendumVote, DeriveReferendumVotes, DeriveReferendumVoteState } from '../types';
|
import type { DeriveReferendum, DeriveReferendumVote, DeriveReferendumVotes, DeriveReferendumVoteState } from '../types';
|
||||||
|
|
||||||
import { BN, bnSqrt, objectSpread } from '@polkadot/util';
|
import { BN, bnSqrt, objectSpread } from '@polkadot/util';
|
||||||
@@ -139,3 +140,21 @@ export function getStatus (info: Option<PalletDemocracyReferendumInfo | Referend
|
|||||||
// done, we don't include it here... only currently active
|
// done, we don't include it here... only currently active
|
||||||
: null;
|
: null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getImageHashBounded (hash: Hash | FrameSupportPreimagesBounded): HexString {
|
||||||
|
return (hash as FrameSupportPreimagesBounded).isLegacy
|
||||||
|
? (hash as FrameSupportPreimagesBounded).asLegacy.hash_.toHex()
|
||||||
|
: (hash as FrameSupportPreimagesBounded).isLookup
|
||||||
|
? (hash as FrameSupportPreimagesBounded).asLookup.hash_.toHex()
|
||||||
|
// for inline, use the actual Bytes hash
|
||||||
|
: (hash as FrameSupportPreimagesBounded).isInline
|
||||||
|
? (hash as FrameSupportPreimagesBounded).asInline.hash.toHex()
|
||||||
|
: hash.toHex();
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getImageHash (status: PalletDemocracyReferendumStatus | ReferendumInfoTo239): HexString {
|
||||||
|
return getImageHashBounded(
|
||||||
|
(status as PalletDemocracyReferendumStatus).proposal ||
|
||||||
|
(status as ReferendumInfoTo239).proposalHash
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/api-derive', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/api-derive', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -47,9 +47,12 @@ function calculateUnlocking (api: DeriveApi, stakingLedger: PalletStakingStaking
|
|||||||
|
|
||||||
function redeemableSum (api: DeriveApi, stakingLedger: PalletStakingStakingLedger | undefined, sessionInfo: DeriveSessionInfo): Balance {
|
function redeemableSum (api: DeriveApi, stakingLedger: PalletStakingStakingLedger | undefined, sessionInfo: DeriveSessionInfo): Balance {
|
||||||
return api.registry.createType('Balance', (stakingLedger?.unlocking || [] as PalletStakingUnlockChunk[]).reduce((total, { era, value }): BN => {
|
return api.registry.createType('Balance', (stakingLedger?.unlocking || [] as PalletStakingUnlockChunk[]).reduce((total, { era, value }): BN => {
|
||||||
return sessionInfo.activeEra.gte(era.unwrap())
|
// aligns with https://github.com/paritytech/substrate/blob/fdfdc73f9e64dc47934b72eb9af3e1989e4ba699/frame/staking/src/pallet/mod.rs#L973-L975
|
||||||
? total.iadd(value.unwrap())
|
// (ensure currentEra >= era passed, as per https://github.com/paritytech/substrate/blob/fdfdc73f9e64dc47934b72eb9af3e1989e4ba699/frame/staking/src/lib.rs#L477-L494)
|
||||||
: total;
|
// NOTE: Previously we used activeEra >= era, which is incorrect for the last session
|
||||||
|
return era.unwrap().gt(sessionInfo.currentEra)
|
||||||
|
? total
|
||||||
|
: total.iadd(value.unwrap());
|
||||||
}, new BN(0)));
|
}, new BN(0)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,12 +2,12 @@
|
|||||||
// SPDX-License-Identifier: Apache-2.0
|
// SPDX-License-Identifier: Apache-2.0
|
||||||
|
|
||||||
import type { Observable } from 'rxjs';
|
import type { Observable } from 'rxjs';
|
||||||
import type { Option, u32 } from '@polkadot/types';
|
import type { u32 } from '@polkadot/types';
|
||||||
import type { ActiveEraInfo, EraIndex } from '@polkadot/types/interfaces';
|
import type { EraIndex } from '@polkadot/types/interfaces';
|
||||||
import type { BN } from '@polkadot/util';
|
import type { BN } from '@polkadot/util';
|
||||||
import type { DeriveApi } from '../types';
|
import type { DeriveApi } from '../types';
|
||||||
|
|
||||||
import { map } from 'rxjs';
|
import { combineLatest, map, of } from 'rxjs';
|
||||||
|
|
||||||
import { BN_ONE, BN_ZERO } from '@polkadot/util';
|
import { BN_ONE, BN_ZERO } from '@polkadot/util';
|
||||||
|
|
||||||
@@ -15,9 +15,11 @@ import { memo } from '../util';
|
|||||||
|
|
||||||
export function erasHistoric (instanceId: string, api: DeriveApi): (withActive?: boolean) => Observable<EraIndex[]> {
|
export function erasHistoric (instanceId: string, api: DeriveApi): (withActive?: boolean) => Observable<EraIndex[]> {
|
||||||
return memo(instanceId, (withActive?: boolean): Observable<EraIndex[]> =>
|
return memo(instanceId, (withActive?: boolean): Observable<EraIndex[]> =>
|
||||||
api.queryMulti<[Option<ActiveEraInfo>, u32]>([
|
combineLatest([
|
||||||
api.query.staking.activeEra,
|
api.query.staking.activeEra(),
|
||||||
api.query.staking.historyDepth
|
api.consts.staking.historyDepth
|
||||||
|
? of(api.consts.staking.historyDepth)
|
||||||
|
: api.query.staking.historyDepth<u32>()
|
||||||
]).pipe(
|
]).pipe(
|
||||||
map(([activeEraOpt, historyDepth]): EraIndex[] => {
|
map(([activeEraOpt, historyDepth]): EraIndex[] => {
|
||||||
const result: EraIndex[] = [];
|
const result: EraIndex[] = [];
|
||||||
|
|||||||
+19
-19
@@ -20,29 +20,29 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/api-base": "9.4.1",
|
"@polkadot/api-base": "9.6.1",
|
||||||
"@polkadot/api-derive": "9.4.1",
|
"@polkadot/api-derive": "9.6.1",
|
||||||
"@polkadot/keyring": "^10.1.8",
|
"@polkadot/keyring": "^10.1.11",
|
||||||
"@polkadot/rpc-augment": "9.4.1",
|
"@polkadot/rpc-augment": "9.6.1",
|
||||||
"@polkadot/rpc-core": "9.4.1",
|
"@polkadot/rpc-core": "9.6.1",
|
||||||
"@polkadot/rpc-provider": "9.4.1",
|
"@polkadot/rpc-provider": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-augment": "9.4.1",
|
"@polkadot/types-augment": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/types-create": "9.4.1",
|
"@polkadot/types-create": "9.6.1",
|
||||||
"@polkadot/types-known": "9.4.1",
|
"@polkadot/types-known": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/util-crypto": "^10.1.8",
|
"@polkadot/util-crypto": "^10.1.11",
|
||||||
"eventemitter3": "^4.0.7",
|
"eventemitter3": "^4.0.7",
|
||||||
"rxjs": "^7.5.6"
|
"rxjs": "^7.5.7"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/types-support": "9.4.1"
|
"@polkadot/types-support": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -791,11 +791,7 @@ export abstract class Decorate<ApiType extends ApiTypes> extends Events {
|
|||||||
key.method === creator.method;
|
key.method === creator.method;
|
||||||
|
|
||||||
decorated.key = (...args: unknown[]): string =>
|
decorated.key = (...args: unknown[]): string =>
|
||||||
u8aToHex(compactStripLength(creator(
|
u8aToHex(compactStripLength(creator(...args))[1]);
|
||||||
creator.meta.type.isPlain
|
|
||||||
? undefined
|
|
||||||
: args
|
|
||||||
))[1]);
|
|
||||||
|
|
||||||
decorated.keyPrefix = (...keys: unknown[]): string =>
|
decorated.keyPrefix = (...keys: unknown[]): string =>
|
||||||
u8aToHex(creator.keyPrefix(...keys));
|
u8aToHex(creator.keyPrefix(...keys));
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ function consts (api: ApiPromise): void {
|
|||||||
api.consts.foo.bar,
|
api.consts.foo.bar,
|
||||||
api.consts.balances.existentialDeposit.toNumber(),
|
api.consts.balances.existentialDeposit.toNumber(),
|
||||||
api.consts.balances.existentialDeposit.meta.docs.map((s) => s.toString()).join(''),
|
api.consts.balances.existentialDeposit.meta.docs.map((s) => s.toString()).join(''),
|
||||||
api.consts.system.blockWeights.maxBlock.divn(123).toNumber()
|
api.consts.system.blockWeights.maxBlock.refTime.toNumber()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -215,6 +215,9 @@ async function rpc (api: ApiPromise): Promise<void> {
|
|||||||
await api.rpc.chain.subscribeNewHeads.raw((result: Uint8Array): void => {
|
await api.rpc.chain.subscribeNewHeads.raw((result: Uint8Array): void => {
|
||||||
console.log(result);
|
console.log(result);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// deprecated methods
|
||||||
|
await api.rpc.state.getPairs('123');
|
||||||
}
|
}
|
||||||
|
|
||||||
function types (api: ApiPromise): void {
|
function types (api: ApiPromise): void {
|
||||||
@@ -266,7 +269,7 @@ async function tx (api: ApiPromise, pairs: TestKeyringMap): Promise<void> {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// it allows for query & then using the submittable
|
// it allows for query & then using the submittable
|
||||||
const second = api.tx.democracy.second(123, 5);
|
const second = api.tx.democracy.second(123);
|
||||||
|
|
||||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||||
await second.signAndSend('123', (result) => console.log(result));
|
await second.signAndSend('123', (result) => console.log(result));
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/api', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/api', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ export function createClass <ApiType extends ApiTypes> ({ api, apiType, blockHas
|
|||||||
|
|
||||||
// dry run an extrinsic
|
// dry run an extrinsic
|
||||||
public dryRun (account: AddressOrPair, optionsOrHash?: Partial<SignerOptions> | Uint8Array | string): SubmittableDryRunResult<ApiType> {
|
public dryRun (account: AddressOrPair, optionsOrHash?: Partial<SignerOptions> | Uint8Array | string): SubmittableDryRunResult<ApiType> {
|
||||||
if (!api.rpc.system || !api.rpc.system.dryRun) {
|
if (!api.rpc.system?.dryRun) {
|
||||||
throw new Error('The system.dryRun RPC call is not available in your environment');
|
throw new Error('The system.dryRun RPC call is not available in your environment');
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -124,7 +124,7 @@ export function createClass <ApiType extends ApiTypes> ({ api, apiType, blockHas
|
|||||||
|
|
||||||
// calculate the payment info for this transaction (if signed and submitted)
|
// calculate the payment info for this transaction (if signed and submitted)
|
||||||
public paymentInfo (account: AddressOrPair, optionsOrHash?: Partial<SignerOptions> | Uint8Array | string): SubmittablePaymentResult<ApiType> {
|
public paymentInfo (account: AddressOrPair, optionsOrHash?: Partial<SignerOptions> | Uint8Array | string): SubmittablePaymentResult<ApiType> {
|
||||||
if (!api.call.transactionPaymentApi || !api.call.transactionPaymentApi.queryInfo) {
|
if (!api.call.transactionPaymentApi?.queryInfo) {
|
||||||
throw new Error('The transactionPaymentApi.queryInfo runtime call is not available in your environment');
|
throw new Error('The transactionPaymentApi.queryInfo runtime call is not available in your environment');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,13 +20,13 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/rpc-core": "9.4.1",
|
"@polkadot/rpc-core": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -142,22 +142,27 @@ declare module '@polkadot/rpc-core/types/jsonrpc' {
|
|||||||
};
|
};
|
||||||
contracts: {
|
contracts: {
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use the runtime interface `api.call.contractsApi.call` instead
|
||||||
* Executes a call to a contract
|
* Executes a call to a contract
|
||||||
**/
|
**/
|
||||||
call: AugmentedRpc<(callRequest: ContractCallRequest | { origin?: any; dest?: any; value?: any; gasLimit?: any; storageDepositLimit?: any; inputData?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<ContractExecResult>>;
|
call: AugmentedRpc<(callRequest: ContractCallRequest | { origin?: any; dest?: any; value?: any; gasLimit?: any; storageDepositLimit?: any; inputData?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<ContractExecResult>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use the runtime interface `api.call.contractsApi.getStorage` instead
|
||||||
* Returns the value under a specified storage key in a contract
|
* Returns the value under a specified storage key in a contract
|
||||||
**/
|
**/
|
||||||
getStorage: AugmentedRpc<(address: AccountId | string | Uint8Array, key: H256 | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<Option<Bytes>>>;
|
getStorage: AugmentedRpc<(address: AccountId | string | Uint8Array, key: H256 | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<Option<Bytes>>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use the runtime interface `api.call.contractsApi.instantiate` instead
|
||||||
* Instantiate a new contract
|
* Instantiate a new contract
|
||||||
**/
|
**/
|
||||||
instantiate: AugmentedRpc<(request: InstantiateRequest | { origin?: any; value?: any; gasLimit?: any; storageDepositLimit?: any; code?: any; data?: any; salt?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<ContractInstantiateResult>>;
|
instantiate: AugmentedRpc<(request: InstantiateRequest | { origin?: any; value?: any; gasLimit?: any; storageDepositLimit?: any; code?: any; data?: any; salt?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<ContractInstantiateResult>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Not available in newer versions of the contracts interfaces
|
||||||
* Returns the projected time a given contract will be able to sustain paying its rent
|
* Returns the projected time a given contract will be able to sustain paying its rent
|
||||||
**/
|
**/
|
||||||
rentProjection: AugmentedRpc<(address: AccountId | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<Option<BlockNumber>>>;
|
rentProjection: AugmentedRpc<(address: AccountId | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<Option<BlockNumber>>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use the runtime interface `api.call.contractsApi.uploadCode` instead
|
||||||
* Upload new code without instantiating a contract from it
|
* Upload new code without instantiating a contract from it
|
||||||
**/
|
**/
|
||||||
uploadCode: AugmentedRpc<(uploadRequest: CodeUploadRequest | { origin?: any; code?: any; storageDepositLimit?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<CodeUploadResult>>;
|
uploadCode: AugmentedRpc<(uploadRequest: CodeUploadRequest | { origin?: any; code?: any; storageDepositLimit?: any } | string | Uint8Array, at?: BlockHash | string | Uint8Array) => Observable<CodeUploadResult>>;
|
||||||
@@ -442,6 +447,7 @@ declare module '@polkadot/rpc-core/types/jsonrpc' {
|
|||||||
**/
|
**/
|
||||||
getChildStorageSize: AugmentedRpc<(childStorageKey: StorageKey | string | Uint8Array | any, childDefinition: StorageKey | string | Uint8Array | any, childType: u32 | AnyNumber | Uint8Array, key: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<u64>>;
|
getChildStorageSize: AugmentedRpc<(childStorageKey: StorageKey | string | Uint8Array | any, childDefinition: StorageKey | string | Uint8Array | any, childType: u32 | AnyNumber | Uint8Array, key: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<u64>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use `api.rpc.state.getKeysPaged` to retrieve keys
|
||||||
* Retrieves the keys with a certain prefix
|
* Retrieves the keys with a certain prefix
|
||||||
**/
|
**/
|
||||||
getKeys: AugmentedRpc<(key: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<Vec<StorageKey>>>;
|
getKeys: AugmentedRpc<(key: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<Vec<StorageKey>>>;
|
||||||
@@ -454,6 +460,7 @@ declare module '@polkadot/rpc-core/types/jsonrpc' {
|
|||||||
**/
|
**/
|
||||||
getMetadata: AugmentedRpc<(at?: BlockHash | string | Uint8Array) => Observable<Metadata>>;
|
getMetadata: AugmentedRpc<(at?: BlockHash | string | Uint8Array) => Observable<Metadata>>;
|
||||||
/**
|
/**
|
||||||
|
* @deprecated Use `api.rpc.state.getKeysPaged` to retrieve keys
|
||||||
* Returns the keys with prefix, leave empty to get all the keys (deprecated: Use getKeysPaged)
|
* Returns the keys with prefix, leave empty to get all the keys (deprecated: Use getKeysPaged)
|
||||||
**/
|
**/
|
||||||
getPairs: AugmentedRpc<(prefix: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<Vec<KeyValue>>>;
|
getPairs: AugmentedRpc<(prefix: StorageKey | string | Uint8Array | any, at?: BlockHash | string | Uint8Array) => Observable<Vec<KeyValue>>>;
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/rpc-augment', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/rpc-augment', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,18 +20,18 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/rpc-augment": "9.4.1",
|
"@polkadot/rpc-augment": "9.6.1",
|
||||||
"@polkadot/rpc-provider": "9.4.1",
|
"@polkadot/rpc-provider": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"rxjs": "^7.5.6"
|
"rxjs": "^7.5.7"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/keyring": "^10.1.8",
|
"@polkadot/keyring": "^10.1.11",
|
||||||
"@polkadot/rpc-augment": "9.4.1"
|
"@polkadot/rpc-augment": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/rpc-core', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/rpc-core', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,19 +20,19 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/keyring": "^10.1.8",
|
"@polkadot/keyring": "^10.1.11",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-support": "9.4.1",
|
"@polkadot/types-support": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/util-crypto": "^10.1.8",
|
"@polkadot/util-crypto": "^10.1.11",
|
||||||
"@polkadot/x-fetch": "^10.1.8",
|
"@polkadot/x-fetch": "^10.1.11",
|
||||||
"@polkadot/x-global": "^10.1.8",
|
"@polkadot/x-global": "^10.1.11",
|
||||||
"@polkadot/x-ws": "^10.1.8",
|
"@polkadot/x-ws": "^10.1.11",
|
||||||
"@substrate/connect": "0.7.13",
|
"@substrate/connect": "0.7.15",
|
||||||
"eventemitter3": "^4.0.7",
|
"eventemitter3": "^4.0.7",
|
||||||
"mock-socket": "^9.1.5",
|
"mock-socket": "^9.1.5",
|
||||||
"nock": "^13.2.9"
|
"nock": "^13.2.9"
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/rpc-provider', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/rpc-provider', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -7,13 +7,15 @@ import type { JsonRpcResponse, ProviderInterface, ProviderInterfaceCallback, Pro
|
|||||||
import { Chain, createScClient, ScClient, WellKnownChain } from '@substrate/connect';
|
import { Chain, createScClient, ScClient, WellKnownChain } from '@substrate/connect';
|
||||||
import EventEmitter from 'eventemitter3';
|
import EventEmitter from 'eventemitter3';
|
||||||
|
|
||||||
import { isError, objectSpread } from '@polkadot/util';
|
import { isError, logger, objectSpread } from '@polkadot/util';
|
||||||
|
|
||||||
import { RpcCoder } from '../coder';
|
import { RpcCoder } from '../coder';
|
||||||
import { healthChecker } from './Health';
|
import { healthChecker } from './Health';
|
||||||
|
|
||||||
type ResponseCallback = (response: string | Error) => void
|
type ResponseCallback = (response: string | Error) => void
|
||||||
|
|
||||||
|
const l = logger('api-substrate-connect');
|
||||||
|
|
||||||
// These methods have been taken from:
|
// These methods have been taken from:
|
||||||
// https://github.com/paritytech/smoldot/blob/17425040ddda47d539556eeaf62b88c4240d1d42/src/json_rpc/methods.rs#L338-L462
|
// https://github.com/paritytech/smoldot/blob/17425040ddda47d539556eeaf62b88c4240d1d42/src/json_rpc/methods.rs#L338-L462
|
||||||
// It's important to take into account that smoldot is adding support to the new
|
// It's important to take into account that smoldot is adding support to the new
|
||||||
@@ -37,11 +39,19 @@ const scClients = new WeakMap<ScProvider, ScClient>();
|
|||||||
|
|
||||||
export { WellKnownChain };
|
export { WellKnownChain };
|
||||||
|
|
||||||
|
interface ActiveSubs {
|
||||||
|
type: string,
|
||||||
|
method: string,
|
||||||
|
params: any[],
|
||||||
|
callback: ProviderInterfaceCallback
|
||||||
|
}
|
||||||
|
|
||||||
export class ScProvider implements ProviderInterface {
|
export class ScProvider implements ProviderInterface {
|
||||||
readonly #coder: RpcCoder = new RpcCoder();
|
readonly #coder: RpcCoder = new RpcCoder();
|
||||||
readonly #spec: string | WellKnownChain;
|
readonly #spec: string | WellKnownChain;
|
||||||
readonly #sharedSandbox?: ScProvider;
|
readonly #sharedSandbox?: ScProvider;
|
||||||
readonly #subscriptions: Map<string, [ResponseCallback, { unsubscribeMethod: string; id: string | number }]> = new Map();
|
readonly #subscriptions: Map<string, [ResponseCallback, { unsubscribeMethod: string; id: string | number }]> = new Map();
|
||||||
|
readonly #resubscribeMethods: Map<string, ActiveSubs> = new Map();
|
||||||
readonly #requests: Map<number, ResponseCallback> = new Map();
|
readonly #requests: Map<number, ResponseCallback> = new Map();
|
||||||
readonly #eventemitter: EventEmitter = new EventEmitter();
|
readonly #eventemitter: EventEmitter = new EventEmitter();
|
||||||
#chain: Promise<Chain> | null = null;
|
#chain: Promise<Chain> | null = null;
|
||||||
@@ -207,11 +217,17 @@ export class ScProvider implements ProviderInterface {
|
|||||||
staleSubscriptions.push(s[1]);
|
staleSubscriptions.push(s[1]);
|
||||||
});
|
});
|
||||||
cleanup();
|
cleanup();
|
||||||
|
|
||||||
|
this.#eventemitter.emit('disconnected');
|
||||||
} else {
|
} else {
|
||||||
killStaleSubscriptions();
|
killStaleSubscriptions();
|
||||||
}
|
|
||||||
|
|
||||||
this.#eventemitter.emit(isReady ? 'connected' : 'disconnected');
|
this.#eventemitter.emit('connected');
|
||||||
|
|
||||||
|
if (this.#resubscribeMethods.size) {
|
||||||
|
this.#resubscribe();
|
||||||
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
return objectSpread({}, chain, {
|
return objectSpread({}, chain, {
|
||||||
@@ -233,6 +249,32 @@ export class ScProvider implements ProviderInterface {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#resubscribe = (): void => {
|
||||||
|
const promises: any[] = [];
|
||||||
|
|
||||||
|
this.#resubscribeMethods.forEach((subDetails: ActiveSubs): void => {
|
||||||
|
// only re-create subscriptions which are not in author (only area where
|
||||||
|
// transactions are created, i.e. submissions such as 'author_submitAndWatchExtrinsic'
|
||||||
|
// are not included (and will not be re-broadcast)
|
||||||
|
if (subDetails.type.startsWith('author_')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
const promise: Promise<void> = new Promise((resolve) => {
|
||||||
|
this.subscribe(subDetails.type, subDetails.method, subDetails.params, subDetails.callback).catch((error) => console.log(error));
|
||||||
|
resolve();
|
||||||
|
});
|
||||||
|
|
||||||
|
promises.push(promise);
|
||||||
|
} catch (error) {
|
||||||
|
l.error(error);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
Promise.all(promises).catch((err) => l.log(err));
|
||||||
|
};
|
||||||
|
|
||||||
async disconnect (): Promise<void> {
|
async disconnect (): Promise<void> {
|
||||||
if (!this.#chain) {
|
if (!this.#chain) {
|
||||||
return;
|
return;
|
||||||
@@ -322,6 +364,8 @@ export class ScProvider implements ProviderInterface {
|
|||||||
throw new Error('Invalid unsubscribe method found');
|
throw new Error('Invalid unsubscribe method found');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.#resubscribeMethods.set(subscriptionId, { callback, method, params, type });
|
||||||
|
|
||||||
this.#subscriptions.set(subscriptionId, [cb, { id, unsubscribeMethod }]);
|
this.#subscriptions.set(subscriptionId, [cb, { id, unsubscribeMethod }]);
|
||||||
|
|
||||||
return id;
|
return id;
|
||||||
@@ -340,6 +384,7 @@ export class ScProvider implements ProviderInterface {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.#resubscribeMethods.delete(subscriptionId);
|
||||||
this.#subscriptions.delete(subscriptionId);
|
this.#subscriptions.delete(subscriptionId);
|
||||||
|
|
||||||
return this.send(method, [id]);
|
return this.send(method, [id]);
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"bin": {
|
"bin": {
|
||||||
"polkadot-types-chain-info": "./scripts/polkadot-types-chain-info.cjs",
|
"polkadot-types-chain-info": "./scripts/polkadot-types-chain-info.cjs",
|
||||||
@@ -30,27 +30,27 @@
|
|||||||
"polkadot-types-internal-metadata": "./scripts/polkadot-types-internal-metadata.cjs"
|
"polkadot-types-internal-metadata": "./scripts/polkadot-types-internal-metadata.cjs"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/core": "^7.19.1",
|
"@babel/core": "^7.19.6",
|
||||||
"@babel/register": "^7.18.9",
|
"@babel/register": "^7.18.9",
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/api": "9.4.1",
|
"@polkadot/api": "9.6.1",
|
||||||
"@polkadot/api-augment": "9.4.1",
|
"@polkadot/api-augment": "9.6.1",
|
||||||
"@polkadot/rpc-augment": "9.4.1",
|
"@polkadot/rpc-augment": "9.6.1",
|
||||||
"@polkadot/rpc-provider": "9.4.1",
|
"@polkadot/rpc-provider": "9.6.1",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-augment": "9.4.1",
|
"@polkadot/types-augment": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/types-create": "9.4.1",
|
"@polkadot/types-create": "9.6.1",
|
||||||
"@polkadot/types-support": "9.4.1",
|
"@polkadot/types-support": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/util-crypto": "^10.1.8",
|
"@polkadot/util-crypto": "^10.1.11",
|
||||||
"@polkadot/x-ws": "^10.1.8",
|
"@polkadot/x-ws": "^10.1.11",
|
||||||
"handlebars": "^4.7.7",
|
"handlebars": "^4.7.7",
|
||||||
"websocket": "^1.0.34",
|
"websocket": "^1.0.34",
|
||||||
"yargs": "^17.5.1"
|
"yargs": "^17.6.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/websocket": "^1.0.5",
|
"@types/websocket": "^1.0.5",
|
||||||
"@types/yargs": "^17.0.12"
|
"@types/yargs": "^17.0.13"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -96,7 +96,9 @@ export function generateRpcTypes (registry: TypeRegistry, importDefinitions: Rec
|
|||||||
|
|
||||||
const item = {
|
const item = {
|
||||||
args: args.join(', '),
|
args: args.join(', '),
|
||||||
docs: [def.description],
|
docs: def.deprecated
|
||||||
|
? [`@deprecated ${def.deprecated}`, def.description]
|
||||||
|
: [def.description],
|
||||||
generic,
|
generic,
|
||||||
name: methodName,
|
name: methodName,
|
||||||
type
|
type
|
||||||
|
|||||||
@@ -98,14 +98,17 @@ function renderPage (page: Page): string {
|
|||||||
? `<h3 id="#${item.link}">${item.name}</h3>`
|
? `<h3 id="#${item.link}">${item.name}</h3>`
|
||||||
: `### ${item.name}`;
|
: `### ${item.name}`;
|
||||||
|
|
||||||
Object.keys(item).filter((key) => !['link', 'name'].includes(key)).forEach((bullet) => {
|
Object
|
||||||
md += `\n- **${bullet}**: ${
|
.keys(item)
|
||||||
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
|
.filter((key) => !['link', 'name'].includes(key))
|
||||||
item[bullet] instanceof Vec
|
.forEach((bullet) => {
|
||||||
? docsVecToMarkdown(item[bullet] as Vec<Text>, 2).toString()
|
md += `\n- **${bullet}**: ${
|
||||||
: item[bullet]
|
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
|
||||||
}`;
|
item[bullet] instanceof Vec
|
||||||
});
|
? docsVecToMarkdown(item[bullet] as Vec<Text>, 2).toString()
|
||||||
|
: item[bullet]
|
||||||
|
}`;
|
||||||
|
});
|
||||||
|
|
||||||
md += '\n';
|
md += '\n';
|
||||||
});
|
});
|
||||||
@@ -160,14 +163,19 @@ function addRpc (): string {
|
|||||||
}).join(', ');
|
}).join(', ');
|
||||||
const type = '`' + method.type + '`';
|
const type = '`' + method.type + '`';
|
||||||
const jsonrpc = (method.endpoint || `${sectionName}_${methodName}`);
|
const jsonrpc = (method.endpoint || `${sectionName}_${methodName}`);
|
||||||
|
const item: SectionItem = {
|
||||||
container.items.push({
|
|
||||||
interface: '`' + `api.rpc.${sectionName}.${methodName}` + '`',
|
interface: '`' + `api.rpc.${sectionName}.${methodName}` + '`',
|
||||||
jsonrpc: '`' + jsonrpc + '`',
|
jsonrpc: '`' + jsonrpc + '`',
|
||||||
// link: jsonrpc,
|
// link: jsonrpc,
|
||||||
name: `${methodName}(${args}): ${type}`,
|
name: `${methodName}(${args}): ${type}`,
|
||||||
...(method.description && { summary: method.description })
|
...(method.description && { summary: method.description })
|
||||||
});
|
};
|
||||||
|
|
||||||
|
if (method.deprecated) {
|
||||||
|
item.deprecated = method.deprecated;
|
||||||
|
}
|
||||||
|
|
||||||
|
container.items.push(item);
|
||||||
});
|
});
|
||||||
|
|
||||||
return all;
|
return all;
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/typegen', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/typegen', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,12 +20,12 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ export default {
|
|||||||
_enum: ['Any', 'NonTransfer', 'Governance', 'Staking', 'IdentityJudgement', 'CancelProxy', 'Auction', 'Society']
|
_enum: ['Any', 'NonTransfer', 'Governance', 'Staking', 'IdentityJudgement', 'CancelProxy', 'Auction', 'Society']
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* Lookup263: kusama_runtime::SessionKeys
|
* Lookup265: kusama_runtime::SessionKeys
|
||||||
**/
|
**/
|
||||||
KusamaRuntimeSessionKeys: {
|
KusamaRuntimeSessionKeys: {
|
||||||
grandpa: 'SpFinalityGrandpaAppPublic',
|
grandpa: 'SpFinalityGrandpaAppPublic',
|
||||||
@@ -22,7 +22,7 @@ export default {
|
|||||||
authorityDiscovery: 'SpAuthorityDiscoveryAppPublic'
|
authorityDiscovery: 'SpAuthorityDiscoveryAppPublic'
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* Lookup338: kusama_runtime::OriginCaller
|
* Lookup340: kusama_runtime::OriginCaller
|
||||||
**/
|
**/
|
||||||
KusamaRuntimeOriginCaller: {
|
KusamaRuntimeOriginCaller: {
|
||||||
_enum: {
|
_enum: {
|
||||||
@@ -129,7 +129,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* Lookup404: kusama_runtime::NposCompactSolution24
|
* Lookup406: kusama_runtime::NposCompactSolution24
|
||||||
**/
|
**/
|
||||||
KusamaRuntimeNposCompactSolution24: {
|
KusamaRuntimeNposCompactSolution24: {
|
||||||
votes1: 'Vec<(Compact<u32>,Compact<u16>)>',
|
votes1: 'Vec<(Compact<u32>,Compact<u16>)>',
|
||||||
@@ -158,7 +158,7 @@ export default {
|
|||||||
votes24: 'Vec<(Compact<u32>,[(Compact<u16>,Compact<PerU16>);23],Compact<u16>)>'
|
votes24: 'Vec<(Compact<u32>,[(Compact<u16>,Compact<PerU16>);23],Compact<u16>)>'
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* Lookup779: kusama_runtime::Runtime
|
* Lookup786: kusama_runtime::Runtime
|
||||||
**/
|
**/
|
||||||
KusamaRuntimeRuntime: 'Null'
|
KusamaRuntimeRuntime: 'Null'
|
||||||
};
|
};
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -23,7 +23,7 @@ declare module '@polkadot/types/lookup' {
|
|||||||
readonly type: 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society';
|
readonly type: 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'IdentityJudgement' | 'CancelProxy' | 'Auction' | 'Society';
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @name KusamaRuntimeSessionKeys (263) */
|
/** @name KusamaRuntimeSessionKeys (265) */
|
||||||
interface KusamaRuntimeSessionKeys extends Struct {
|
interface KusamaRuntimeSessionKeys extends Struct {
|
||||||
readonly grandpa: SpFinalityGrandpaAppPublic;
|
readonly grandpa: SpFinalityGrandpaAppPublic;
|
||||||
readonly babe: SpConsensusBabeAppPublic;
|
readonly babe: SpConsensusBabeAppPublic;
|
||||||
@@ -33,7 +33,7 @@ declare module '@polkadot/types/lookup' {
|
|||||||
readonly authorityDiscovery: SpAuthorityDiscoveryAppPublic;
|
readonly authorityDiscovery: SpAuthorityDiscoveryAppPublic;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @name KusamaRuntimeOriginCaller (338) */
|
/** @name KusamaRuntimeOriginCaller (340) */
|
||||||
interface KusamaRuntimeOriginCaller extends Enum {
|
interface KusamaRuntimeOriginCaller extends Enum {
|
||||||
readonly isSystem: boolean;
|
readonly isSystem: boolean;
|
||||||
readonly asSystem: FrameSupportDispatchRawOrigin;
|
readonly asSystem: FrameSupportDispatchRawOrigin;
|
||||||
@@ -49,7 +49,7 @@ declare module '@polkadot/types/lookup' {
|
|||||||
readonly type: 'System' | 'Void' | 'Council' | 'TechnicalCommittee' | 'ParachainsOrigin' | 'XcmPallet';
|
readonly type: 'System' | 'Void' | 'Council' | 'TechnicalCommittee' | 'ParachainsOrigin' | 'XcmPallet';
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @name KusamaRuntimeNposCompactSolution24 (404) */
|
/** @name KusamaRuntimeNposCompactSolution24 (406) */
|
||||||
interface KusamaRuntimeNposCompactSolution24 extends Struct {
|
interface KusamaRuntimeNposCompactSolution24 extends Struct {
|
||||||
readonly votes1: Vec<ITuple<[Compact<u32>, Compact<u16>]>>;
|
readonly votes1: Vec<ITuple<[Compact<u32>, Compact<u16>]>>;
|
||||||
readonly votes2: Vec<ITuple<[Compact<u32>, ITuple<[Compact<u16>, Compact<PerU16>]>, Compact<u16>]>>;
|
readonly votes2: Vec<ITuple<[Compact<u32>, ITuple<[Compact<u16>, Compact<PerU16>]>, Compact<u16>]>>;
|
||||||
@@ -77,7 +77,7 @@ declare module '@polkadot/types/lookup' {
|
|||||||
readonly votes24: Vec<ITuple<[Compact<u32>, Vec<ITuple<[Compact<u16>, Compact<PerU16>]>>, Compact<u16>]>>;
|
readonly votes24: Vec<ITuple<[Compact<u32>, Vec<ITuple<[Compact<u16>, Compact<PerU16>]>>, Compact<u16>]>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @name KusamaRuntimeRuntime (779) */
|
/** @name KusamaRuntimeRuntime (786) */
|
||||||
type KusamaRuntimeRuntime = Null;
|
type KusamaRuntimeRuntime = Null;
|
||||||
|
|
||||||
} // declare module
|
} // declare module
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/types-augment', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/types-augment', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ import type { ProxyAnnouncement, ProxyDefinition, ProxyType } from '@polkadot/ty
|
|||||||
import type { AccountStatus, AccountValidity } from '@polkadot/types/interfaces/purchase';
|
import type { AccountStatus, AccountValidity } from '@polkadot/types/interfaces/purchase';
|
||||||
import type { ActiveRecovery, RecoveryConfig } from '@polkadot/types/interfaces/recovery';
|
import type { ActiveRecovery, RecoveryConfig } from '@polkadot/types/interfaces/recovery';
|
||||||
import type { RpcMethods } from '@polkadot/types/interfaces/rpc';
|
import type { RpcMethods } from '@polkadot/types/interfaces/rpc';
|
||||||
import type { AccountId, AccountId20, AccountId32, AccountId33, AccountIdOf, AccountIndex, Address, AssetId, Balance, BalanceOf, Block, BlockNumber, BlockNumberFor, BlockNumberOf, Call, CallHash, CallHashOf, ChangesTrieConfiguration, ChangesTrieSignal, CodecHash, Consensus, ConsensusEngineId, CrateVersion, Digest, DigestItem, EncodedJustification, ExtrinsicsWeight, Fixed128, Fixed64, FixedI128, FixedI64, FixedU128, FixedU64, H1024, H128, H160, H2048, H256, H32, H512, H64, Hash, Header, HeaderPartial, I32F32, Index, IndicesLookupSource, Justification, Justifications, KeyTypeId, KeyValue, LockIdentifier, LookupSource, LookupTarget, ModuleId, Moment, MultiAddress, MultiSigner, OpaqueCall, Origin, OriginCaller, PalletId, PalletVersion, PalletsOrigin, Pays, PerU16, Perbill, Percent, Permill, Perquintill, Phantom, PhantomData, PreRuntime, Releases, RuntimeDbWeight, Seal, SealV0, SignedBlock, SignedBlockWithJustification, SignedBlockWithJustifications, Slot, SlotDuration, StorageData, StorageInfo, StorageProof, TransactionInfo, TransactionLongevity, TransactionPriority, TransactionStorageProof, TransactionTag, U32F32, ValidatorId, ValidatorIdOf, Weight, WeightMultiplier } from '@polkadot/types/interfaces/runtime';
|
import type { AccountId, AccountId20, AccountId32, AccountId33, AccountIdOf, AccountIndex, Address, AssetId, Balance, BalanceOf, Block, BlockNumber, BlockNumberFor, BlockNumberOf, Call, CallHash, CallHashOf, ChangesTrieConfiguration, ChangesTrieSignal, CodecHash, Consensus, ConsensusEngineId, CrateVersion, Digest, DigestItem, EncodedJustification, ExtrinsicsWeight, Fixed128, Fixed64, FixedI128, FixedI64, FixedU128, FixedU64, H1024, H128, H160, H2048, H256, H32, H512, H64, Hash, Header, HeaderPartial, I32F32, Index, IndicesLookupSource, Justification, Justifications, KeyTypeId, KeyValue, LockIdentifier, LookupSource, LookupTarget, ModuleId, Moment, MultiAddress, MultiSigner, OpaqueCall, Origin, OriginCaller, PalletId, PalletVersion, PalletsOrigin, Pays, PerU16, Perbill, Percent, Permill, Perquintill, Phantom, PhantomData, PreRuntime, Releases, RuntimeDbWeight, Seal, SealV0, SignedBlock, SignedBlockWithJustification, SignedBlockWithJustifications, Slot, SlotDuration, StorageData, StorageInfo, StorageProof, TransactionInfo, TransactionLongevity, TransactionPriority, TransactionStorageProof, TransactionTag, U32F32, ValidatorId, ValidatorIdOf, Weight, WeightMultiplier, WeightV1, WeightV2 } from '@polkadot/types/interfaces/runtime';
|
||||||
import type { Si0Field, Si0LookupTypeId, Si0Path, Si0Type, Si0TypeDef, Si0TypeDefArray, Si0TypeDefBitSequence, Si0TypeDefCompact, Si0TypeDefComposite, Si0TypeDefPhantom, Si0TypeDefPrimitive, Si0TypeDefSequence, Si0TypeDefTuple, Si0TypeDefVariant, Si0TypeParameter, Si0Variant, Si1Field, Si1LookupTypeId, Si1Path, Si1Type, Si1TypeDef, Si1TypeDefArray, Si1TypeDefBitSequence, Si1TypeDefCompact, Si1TypeDefComposite, Si1TypeDefPrimitive, Si1TypeDefSequence, Si1TypeDefTuple, Si1TypeDefVariant, Si1TypeParameter, Si1Variant, SiField, SiLookupTypeId, SiPath, SiType, SiTypeDef, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefPrimitive, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '@polkadot/types/interfaces/scaleInfo';
|
import type { Si0Field, Si0LookupTypeId, Si0Path, Si0Type, Si0TypeDef, Si0TypeDefArray, Si0TypeDefBitSequence, Si0TypeDefCompact, Si0TypeDefComposite, Si0TypeDefPhantom, Si0TypeDefPrimitive, Si0TypeDefSequence, Si0TypeDefTuple, Si0TypeDefVariant, Si0TypeParameter, Si0Variant, Si1Field, Si1LookupTypeId, Si1Path, Si1Type, Si1TypeDef, Si1TypeDefArray, Si1TypeDefBitSequence, Si1TypeDefCompact, Si1TypeDefComposite, Si1TypeDefPrimitive, Si1TypeDefSequence, Si1TypeDefTuple, Si1TypeDefVariant, Si1TypeParameter, Si1Variant, SiField, SiLookupTypeId, SiPath, SiType, SiTypeDef, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefPrimitive, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '@polkadot/types/interfaces/scaleInfo';
|
||||||
import type { Period, Priority, SchedulePeriod, SchedulePriority, Scheduled, ScheduledTo254, TaskAddress } from '@polkadot/types/interfaces/scheduler';
|
import type { Period, Priority, SchedulePeriod, SchedulePriority, Scheduled, ScheduledTo254, TaskAddress } from '@polkadot/types/interfaces/scheduler';
|
||||||
import type { BeefyKey, FullIdentification, IdentificationTuple, Keys, MembershipProof, SessionIndex, SessionKeys1, SessionKeys10, SessionKeys10B, SessionKeys2, SessionKeys3, SessionKeys4, SessionKeys5, SessionKeys6, SessionKeys6B, SessionKeys7, SessionKeys7B, SessionKeys8, SessionKeys8B, SessionKeys9, SessionKeys9B, ValidatorCount } from '@polkadot/types/interfaces/session';
|
import type { BeefyKey, FullIdentification, IdentificationTuple, Keys, MembershipProof, SessionIndex, SessionKeys1, SessionKeys10, SessionKeys10B, SessionKeys2, SessionKeys3, SessionKeys4, SessionKeys5, SessionKeys6, SessionKeys6B, SessionKeys7, SessionKeys7B, SessionKeys8, SessionKeys8B, SessionKeys9, SessionKeys9B, ValidatorCount } from '@polkadot/types/interfaces/session';
|
||||||
@@ -1149,6 +1149,8 @@ declare module '@polkadot/types/types/registry' {
|
|||||||
WeightMultiplier: WeightMultiplier;
|
WeightMultiplier: WeightMultiplier;
|
||||||
WeightPerClass: WeightPerClass;
|
WeightPerClass: WeightPerClass;
|
||||||
WeightToFeeCoefficient: WeightToFeeCoefficient;
|
WeightToFeeCoefficient: WeightToFeeCoefficient;
|
||||||
|
WeightV1: WeightV1;
|
||||||
|
WeightV2: WeightV2;
|
||||||
WildFungibility: WildFungibility;
|
WildFungibility: WildFungibility;
|
||||||
WildFungibilityV0: WildFungibilityV0;
|
WildFungibilityV0: WildFungibilityV0;
|
||||||
WildFungibilityV1: WildFungibilityV1;
|
WildFungibilityV1: WildFungibilityV1;
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -20,17 +20,17 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/util": "^10.1.8",
|
"@polkadot/util": "^10.1.11",
|
||||||
"@polkadot/x-bigint": "^10.1.8"
|
"@polkadot/x-bigint": "^10.1.11"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-augment": "9.4.1",
|
"@polkadot/types-augment": "9.6.1",
|
||||||
"@polkadot/types-support": "9.4.1",
|
"@polkadot/types-support": "9.6.1",
|
||||||
"@polkadot/util-crypto": "^10.1.8"
|
"@polkadot/util-crypto": "^10.1.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/types-codec', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/types-codec', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,14 +20,14 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/types": "9.4.1"
|
"@polkadot/types": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/types-create', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/types-create', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -20,17 +20,17 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/networks": "^10.1.8",
|
"@polkadot/networks": "^10.1.11",
|
||||||
"@polkadot/types": "9.4.1",
|
"@polkadot/types": "9.6.1",
|
||||||
"@polkadot/types-codec": "9.4.1",
|
"@polkadot/types-codec": "9.6.1",
|
||||||
"@polkadot/types-create": "9.4.1",
|
"@polkadot/types-create": "9.6.1",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@polkadot/api": "9.4.1"
|
"@polkadot/api": "9.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
// Do not edit, auto-generated by @polkadot/dev
|
// Do not edit, auto-generated by @polkadot/dev
|
||||||
|
|
||||||
export const packageInfo = { name: '@polkadot/types-known', path: 'auto', type: 'auto', version: '9.4.1' };
|
export const packageInfo = { name: '@polkadot/types-known', path: 'auto', type: 'auto', version: '9.6.1' };
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ const sharedTypes = {
|
|||||||
ProxyType: {
|
ProxyType: {
|
||||||
_enum: ['Any', 'NonTransfer', 'Governance', 'Staking', 'IdentityJudgement', 'CancelProxy', 'Auction']
|
_enum: ['Any', 'NonTransfer', 'Governance', 'Staking', 'IdentityJudgement', 'CancelProxy', 'Auction']
|
||||||
},
|
},
|
||||||
Weight: 'u64'
|
Weight: 'WeightV1'
|
||||||
};
|
};
|
||||||
|
|
||||||
const addrIndicesTypes = {
|
const addrIndicesTypes = {
|
||||||
@@ -202,8 +202,18 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
{
|
{
|
||||||
// metadata v14
|
// metadata v14
|
||||||
minmax: [9106, undefined],
|
minmax: [9106, undefined],
|
||||||
types: {}
|
types: {
|
||||||
|
Weight: 'WeightV1'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// ,
|
||||||
|
// {
|
||||||
|
// // weight v2 introduction
|
||||||
|
// minmax: [9300, undefined],
|
||||||
|
// types: {
|
||||||
|
// Weight: 'WeightV2'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
];
|
];
|
||||||
|
|
||||||
export default versioned;
|
export default versioned;
|
||||||
|
|||||||
@@ -10,6 +10,8 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
minmax: [0, undefined],
|
minmax: [0, undefined],
|
||||||
types: {
|
types: {
|
||||||
// nothing, API tracks master
|
// nothing, API tracks master
|
||||||
|
// (v2 weights are not yet the default)
|
||||||
|
Weight: 'WeightV2'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -10,6 +10,8 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
minmax: [0, undefined],
|
minmax: [0, undefined],
|
||||||
types: {
|
types: {
|
||||||
// nothing, API tracks master
|
// nothing, API tracks master
|
||||||
|
// (v2 weights are not yet the default)
|
||||||
|
Weight: 'WeightV2'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ const sharedTypes = {
|
|||||||
Auction: 7
|
Auction: 7
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
Weight: 'u64'
|
Weight: 'WeightV1'
|
||||||
};
|
};
|
||||||
|
|
||||||
const addrAccountIdTypes = {
|
const addrAccountIdTypes = {
|
||||||
@@ -76,8 +76,18 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
{
|
{
|
||||||
// metadata v14
|
// metadata v14
|
||||||
minmax: [9110, undefined],
|
minmax: [9110, undefined],
|
||||||
types: {}
|
types: {
|
||||||
|
Weight: 'WeightV1'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// ,
|
||||||
|
// {
|
||||||
|
// // weight v2 introduction
|
||||||
|
// minmax: [9300, undefined],
|
||||||
|
// types: {
|
||||||
|
// Weight: 'WeightV2'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
];
|
];
|
||||||
|
|
||||||
export default versioned;
|
export default versioned;
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ const sharedTypes = {
|
|||||||
DispatchErrorModule: 'DispatchErrorModuleU8',
|
DispatchErrorModule: 'DispatchErrorModuleU8',
|
||||||
FullIdentification: '()', // No staking, only session (as per config)
|
FullIdentification: '()', // No staking, only session (as per config)
|
||||||
Keys: 'SessionKeys7B',
|
Keys: 'SessionKeys7B',
|
||||||
Weight: 'u64'
|
Weight: 'WeightV1'
|
||||||
};
|
};
|
||||||
|
|
||||||
const versioned: OverrideVersionedType[] = [
|
const versioned: OverrideVersionedType[] = [
|
||||||
@@ -50,8 +50,18 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
{
|
{
|
||||||
// metadata v14
|
// metadata v14
|
||||||
minmax: [9106, undefined],
|
minmax: [9106, undefined],
|
||||||
types: {}
|
types: {
|
||||||
|
Weight: 'WeightV1'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// ,
|
||||||
|
// {
|
||||||
|
// // weight v2 introduction
|
||||||
|
// minmax: [9300, undefined],
|
||||||
|
// types: {
|
||||||
|
// Weight: 'WeightV2'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
];
|
];
|
||||||
|
|
||||||
export default versioned;
|
export default versioned;
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ const sharedTypes = {
|
|||||||
'Staking'
|
'Staking'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
Weight: 'u64'
|
Weight: 'WeightV1'
|
||||||
};
|
};
|
||||||
|
|
||||||
// these are override types for Statemine, Statemint, Westmint
|
// these are override types for Statemine, Statemint, Westmint
|
||||||
@@ -42,8 +42,18 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
{
|
{
|
||||||
// metadata V14
|
// metadata V14
|
||||||
minmax: [500, undefined],
|
minmax: [500, undefined],
|
||||||
types: {}
|
types: {
|
||||||
|
Weight: 'WeightV1'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// ,
|
||||||
|
// {
|
||||||
|
// // weight v2 introduction
|
||||||
|
// minmax: [9300, undefined],
|
||||||
|
// types: {
|
||||||
|
// Weight: 'WeightV2'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
];
|
];
|
||||||
|
|
||||||
export default versioned;
|
export default versioned;
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ const sharedTypes = {
|
|||||||
ProxyType: {
|
ProxyType: {
|
||||||
_enum: ['Any', 'NonTransfer', 'Staking', 'SudoBalances', 'IdentityJudgement', 'CancelProxy']
|
_enum: ['Any', 'NonTransfer', 'Staking', 'SudoBalances', 'IdentityJudgement', 'CancelProxy']
|
||||||
},
|
},
|
||||||
Weight: 'u64'
|
Weight: 'WeightV1'
|
||||||
};
|
};
|
||||||
|
|
||||||
const addrAccountIdTypes = {
|
const addrAccountIdTypes = {
|
||||||
@@ -93,8 +93,18 @@ const versioned: OverrideVersionedType[] = [
|
|||||||
{
|
{
|
||||||
// metadata v14
|
// metadata v14
|
||||||
minmax: [9106, undefined],
|
minmax: [9106, undefined],
|
||||||
types: {}
|
types: {
|
||||||
|
Weight: 'WeightV1'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
// ,
|
||||||
|
// {
|
||||||
|
// // weight v2 introduction
|
||||||
|
// minmax: [9300, undefined],
|
||||||
|
// types: {
|
||||||
|
// Weight: 'WeightV2'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
];
|
];
|
||||||
|
|
||||||
export default versioned;
|
export default versioned;
|
||||||
|
|||||||
@@ -3828,6 +3828,76 @@ const upgrades: ChainUpgradesGenerated = [
|
|||||||
1
|
1
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
],
|
||||||
|
[
|
||||||
|
14645900,
|
||||||
|
9291,
|
||||||
|
[
|
||||||
|
[
|
||||||
|
"0xdf6acb689907609b",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37e397fc7c91f5e4",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x40fe3ad401f8959a",
|
||||||
|
6
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xd2bc9897eed08f15",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf78b278be53f454c",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xaf2c0297a23e6d3d",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x49eaaf1b548a0cb0",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x91d5df18b0d2cf58",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xed99c5acb25eedf5",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xcbca25e39f142387",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x687ad44ad37f03c2",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xab3c0572291feb8b",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xbc9d89904f5b923f",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37c8bb1350a9a2a8",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf3ff14d5ab527059",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x17a6bc0d0062aeb3",
|
||||||
|
1
|
||||||
|
]
|
||||||
|
]
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -2356,6 +2356,208 @@ const upgrades: ChainUpgradesGenerated = [
|
|||||||
1
|
1
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
],
|
||||||
|
[
|
||||||
|
12217535,
|
||||||
|
9280,
|
||||||
|
[
|
||||||
|
[
|
||||||
|
"0xdf6acb689907609b",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37e397fc7c91f5e4",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x40fe3ad401f8959a",
|
||||||
|
6
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xd2bc9897eed08f15",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf78b278be53f454c",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xaf2c0297a23e6d3d",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x49eaaf1b548a0cb0",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x91d5df18b0d2cf58",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xed99c5acb25eedf5",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xcbca25e39f142387",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x687ad44ad37f03c2",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xab3c0572291feb8b",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xbc9d89904f5b923f",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37c8bb1350a9a2a8",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf3ff14d5ab527059",
|
||||||
|
1
|
||||||
|
]
|
||||||
|
]
|
||||||
|
],
|
||||||
|
[
|
||||||
|
12245277,
|
||||||
|
9281,
|
||||||
|
[
|
||||||
|
[
|
||||||
|
"0xdf6acb689907609b",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37e397fc7c91f5e4",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x40fe3ad401f8959a",
|
||||||
|
6
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xd2bc9897eed08f15",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf78b278be53f454c",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xaf2c0297a23e6d3d",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x49eaaf1b548a0cb0",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x91d5df18b0d2cf58",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xed99c5acb25eedf5",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xcbca25e39f142387",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x687ad44ad37f03c2",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xab3c0572291feb8b",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xbc9d89904f5b923f",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37c8bb1350a9a2a8",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf3ff14d5ab527059",
|
||||||
|
1
|
||||||
|
]
|
||||||
|
]
|
||||||
|
],
|
||||||
|
[
|
||||||
|
12532644,
|
||||||
|
9291,
|
||||||
|
[
|
||||||
|
[
|
||||||
|
"0xdf6acb689907609b",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37e397fc7c91f5e4",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x40fe3ad401f8959a",
|
||||||
|
6
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x17a6bc0d0062aeb3",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xd2bc9897eed08f15",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf78b278be53f454c",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xaf2c0297a23e6d3d",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x49eaaf1b548a0cb0",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x91d5df18b0d2cf58",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xed99c5acb25eedf5",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xcbca25e39f142387",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x687ad44ad37f03c2",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xab3c0572291feb8b",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xbc9d89904f5b923f",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37c8bb1350a9a2a8",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf3ff14d5ab527059",
|
||||||
|
1
|
||||||
|
]
|
||||||
|
]
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -3596,6 +3596,76 @@ const upgrades: ChainUpgradesGenerated = [
|
|||||||
1
|
1
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
],
|
||||||
|
[
|
||||||
|
12841034,
|
||||||
|
9300,
|
||||||
|
[
|
||||||
|
[
|
||||||
|
"0xdf6acb689907609b",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37e397fc7c91f5e4",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x40fe3ad401f8959a",
|
||||||
|
6
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xd2bc9897eed08f15",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf78b278be53f454c",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xaf2c0297a23e6d3d",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x49eaaf1b548a0cb0",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x91d5df18b0d2cf58",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xed99c5acb25eedf5",
|
||||||
|
3
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xcbca25e39f142387",
|
||||||
|
2
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x687ad44ad37f03c2",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xab3c0572291feb8b",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xbc9d89904f5b923f",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x37c8bb1350a9a2a8",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0xf3ff14d5ab527059",
|
||||||
|
1
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"0x17a6bc0d0062aeb3",
|
||||||
|
1
|
||||||
|
]
|
||||||
|
]
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ const upgrades: ChainUpgradesManual = [
|
|||||||
[9611377, 9100], [9625129, 9111], [9866422, 9122], [10403784, 9130], [10960765, 9150],
|
[9611377, 9100], [9625129, 9111], [9866422, 9122], [10403784, 9130], [10960765, 9150],
|
||||||
[11006614, 9151], [11404482, 9160], [11601803, 9170], [12008022, 9180], [12405451, 9190],
|
[11006614, 9151], [11404482, 9160], [11601803, 9170], [12008022, 9180], [12405451, 9190],
|
||||||
[12665416, 9200], [12909508, 9220], [13109752, 9230], [13555777, 9250], [13727747, 9260],
|
[12665416, 9200], [12909508, 9220], [13109752, 9230], [13555777, 9250], [13727747, 9260],
|
||||||
[14248044, 9271], [14433840, 9280]
|
[14248044, 9271], [14433840, 9280], [14645900, 9291]
|
||||||
];
|
];
|
||||||
|
|
||||||
export default upgrades;
|
export default upgrades;
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ const upgrades: ChainUpgradesManual = [
|
|||||||
[6321619, 9080], [6713249, 9090], [7217907, 9100], [7229126, 9110], [7560558, 9122],
|
[6321619, 9080], [6713249, 9090], [7217907, 9100], [7229126, 9110], [7560558, 9122],
|
||||||
[8115869, 9140], [8638103, 9151], [9280179, 9170], [9738717, 9180], [10156856, 9190],
|
[8115869, 9140], [8638103, 9151], [9280179, 9170], [9738717, 9180], [10156856, 9190],
|
||||||
[10458576, 9200], [10655116, 9220], [10879371, 9230], [11328884, 9250], [11532856, 9260],
|
[10458576, 9200], [10655116, 9220], [10879371, 9230], [11328884, 9250], [11532856, 9260],
|
||||||
[11933818, 9270]
|
[11933818, 9270], [12217535, 9280], [12245277, 9281], [12532644, 9291]
|
||||||
];
|
];
|
||||||
|
|
||||||
export default upgrades;
|
export default upgrades;
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ const upgrades: ChainUpgradesManual = [
|
|||||||
[9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200],
|
[9406726, 9160], [9921066, 9170], [10007115, 9180], [10480973, 9190], [10578091, 9200],
|
||||||
[10678509, 9210], [10811001, 9220], [11096116, 9230], [11409279, 9250], [11584820, 9251],
|
[10678509, 9210], [10811001, 9220], [11096116, 9230], [11409279, 9250], [11584820, 9251],
|
||||||
[11716837, 9260], [11876919, 9261], [11987927, 9270], [12077324, 9271], [12301871, 9280],
|
[11716837, 9260], [11876919, 9261], [11987927, 9270], [12077324, 9271], [12301871, 9280],
|
||||||
[12604343, 9290]
|
[12604343, 9290], [12841034, 9300]
|
||||||
];
|
];
|
||||||
|
|
||||||
export default upgrades;
|
export default upgrades;
|
||||||
|
|||||||
@@ -20,10 +20,10 @@
|
|||||||
"./detectPackage.cjs"
|
"./detectPackage.cjs"
|
||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "9.4.1",
|
"version": "9.6.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.19.0",
|
"@babel/runtime": "^7.19.4",
|
||||||
"@polkadot/util": "^10.1.8"
|
"@polkadot/util": "^10.1.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
"changes": [
|
"changes": [
|
||||||
[
|
[
|
||||||
"0xcc956bdb7605e3547539f321ac2bc95c",
|
"0xcc956bdb7605e3547539f321ac2bc95c",
|
||||||
"0x08000000000000000000010000000000000000000000000000000000000000000000000000"
|
"0x08000000000000000000010000000000000000000000000000"
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user