Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4c2593629d | ||
|
|
612d85ca2a | ||
|
|
b25b92dddc | ||
|
|
f01376ebe1 | ||
|
|
03acde19b8 | ||
|
|
1de533ca9c | ||
|
|
ce2037400c | ||
|
|
379fe12979 | ||
|
|
a285f53753 | ||
|
|
ed36eed112 | ||
|
|
ddf6f574f6 | ||
|
|
4f7c4e8b4e | ||
|
|
f2a82ddd0f | ||
|
|
3cec316683 | ||
|
|
c23b5e674b | ||
|
|
8bf8222c31 | ||
|
|
0c19e966cc | ||
|
|
9fbda5a6e0 | ||
|
|
3d7d39073f | ||
|
|
ae26aebdf8 | ||
|
|
c43f442fb9 | ||
|
|
f97a6d0418 | ||
|
|
7cd2fa5f6a | ||
|
|
6015552aab | ||
|
|
8748c02b20 | ||
|
|
6e04d4aa93 | ||
|
|
4a955f7b77 | ||
|
|
227143728d | ||
|
|
7330555c37 |
@@ -1,5 +1,25 @@
|
||||
# CHANGELOG
|
||||
|
||||
## 4.15.1 Jun 19, 2021
|
||||
|
||||
Upgrade priority: Medium. Recommended for all chains where Xcm is used (addition of new `XcmOrigin`)
|
||||
|
||||
Contributed:
|
||||
|
||||
- Added `ChargeAssetTxPayment` extension (Thanks to https://github.com/apopiak)
|
||||
|
||||
Changes:
|
||||
|
||||
- Allow for type decoding of nested fixed vectors, tuples and structs
|
||||
- Added `childstate_getKeysPaged` RPC
|
||||
- Add `XcmOrigin` mapping for `OriginCaller` generation
|
||||
- Align static metadata with latest Substrate
|
||||
- Adjust error message for contracts V3 (extrinsic from runtime)
|
||||
- Correct module optionality in `api.derive.balances.account`
|
||||
- Add alias for `GenericAddress` -> `GenericMultiAddress`
|
||||
- Adjust metadata doc generation (keep spaces between subsequent lines)
|
||||
|
||||
|
||||
## 4.14.1 Jun 14, 2021
|
||||
|
||||
Upgrade priority: Low. Internal adjustment only, no major external usage changes.
|
||||
|
||||
+2
-2
@@ -20,7 +20,7 @@
|
||||
"lint": "polkadot-dev-run-lint",
|
||||
"clean": "polkadot-dev-clean-build",
|
||||
"postinstall": "polkadot-dev-yarn-only",
|
||||
"test": "polkadot-dev-run-test --coverage --detectOpenHandles --forceExit --runInBand --testPathIgnorePatterns e2e",
|
||||
"test": "polkadot-dev-run-test --coverage --forceExit --runInBand --testPathIgnorePatterns e2e",
|
||||
"test:one": "polkadot-dev-run-test --detectOpenHandles --forceExit",
|
||||
"test:watch": "polkadot-dev-run-test --watch"
|
||||
},
|
||||
@@ -34,5 +34,5 @@
|
||||
"@types/jest": "^26.0.23",
|
||||
"copyfiles": "^2.4.1"
|
||||
},
|
||||
"version": "4.14.1"
|
||||
"version": "4.15.1"
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api-contract",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Interfaces for interacting with contracts and contract ABIs",
|
||||
"main": "index.js",
|
||||
@@ -20,9 +20,9 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api-contract#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/api": "4.14.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/x-rxjs": "^6.8.1"
|
||||
"@polkadot/api": "4.15.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/x-rxjs": "^6.9.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,6 +26,7 @@ export abstract class Base<ApiType extends ApiTypes> {
|
||||
this.registry = this.abi.registry;
|
||||
this._decorateMethod = decorateMethod;
|
||||
|
||||
assert(isFunction(api.rx.tx.contracts?.instantiateWithCode), 'You need to connect to a node with a V3 contracts module. Your node does not expose api.tx.contracts.instantiateWithCode on this instance');
|
||||
assert(!!(api && api.isConnected && api.tx && api.tx.contracts && Object.keys(api.tx.contracts).length), 'Your API has not been initialized correctly and it not decorated with the runtime interfaces for contracts as retrieved from the on-chain runtime');
|
||||
assert(isFunction(api.tx.contracts.instantiateWithCode), 'You need to connect to a chain with a runtime with a V3 contracts module. The runtime does not expose api.tx.contracts.instantiateWithCode');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,13 +7,12 @@ import { TypeRegistry } from '@polkadot/types';
|
||||
const registry = new TypeRegistry();
|
||||
|
||||
export const mockApi = {
|
||||
isConnected: true,
|
||||
registry,
|
||||
rx: {
|
||||
tx: {
|
||||
contracts: {
|
||||
instantiateWithCode: (): never => {
|
||||
throw new Error('mock');
|
||||
}
|
||||
tx: {
|
||||
contracts: {
|
||||
instantiateWithCode: (): never => {
|
||||
throw new Error('mock');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api-contract', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/api-contract', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api-derive",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Common functions used across Polkadot, derived from RPC calls and storage queries.",
|
||||
"main": "index.js",
|
||||
@@ -20,15 +20,15 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api-derive#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/api": "4.14.1",
|
||||
"@polkadot/rpc-core": "4.14.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/util-crypto": "^6.8.1",
|
||||
"@polkadot/x-rxjs": "^6.8.1"
|
||||
"@polkadot/api": "4.15.1",
|
||||
"@polkadot/rpc-core": "4.15.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/util-crypto": "^6.9.1",
|
||||
"@polkadot/x-rxjs": "^6.9.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^6.8.1",
|
||||
"@polkadot/rpc-provider": "4.14.1"
|
||||
"@polkadot/keyring": "^6.9.1",
|
||||
"@polkadot/rpc-provider": "4.15.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,13 +23,19 @@ type DeriveCustomAccount = ApiInterfaceRx['derive'] & {
|
||||
}
|
||||
}
|
||||
|
||||
function zeroBalance (api: ApiInterfaceRx) {
|
||||
return api.registry.createType('Balance');
|
||||
}
|
||||
|
||||
function getBalance (api: ApiInterfaceRx, [freeBalance, reservedBalance, frozenFee, frozenMisc]: BalanceResult): DeriveBalancesAccountData {
|
||||
const votingBalance = api.registry.createType('Balance', freeBalance.toBn());
|
||||
|
||||
return {
|
||||
freeBalance,
|
||||
frozenFee,
|
||||
frozenMisc,
|
||||
reservedBalance,
|
||||
votingBalance: api.registry.createType('Balance', freeBalance.toBn())
|
||||
votingBalance
|
||||
};
|
||||
}
|
||||
|
||||
@@ -55,7 +61,16 @@ function queryBalancesFree (api: ApiInterfaceRx, accountId: AccountId): Observab
|
||||
]).pipe(
|
||||
map(([freeBalance, reservedBalance, accountNonce]): Result => [
|
||||
accountNonce,
|
||||
[[freeBalance, reservedBalance, api.registry.createType('Balance'), api.registry.createType('Balance')]]
|
||||
[[freeBalance, reservedBalance, zeroBalance(api), zeroBalance(api)]]
|
||||
])
|
||||
);
|
||||
}
|
||||
|
||||
function querySystemNonce (api: ApiInterfaceRx, accountId: AccountId): Observable<Result> {
|
||||
return api.query.system.accountNonce<Index>(accountId).pipe(
|
||||
map((accountNonce): Result => [
|
||||
accountNonce,
|
||||
[[zeroBalance(api), zeroBalance(api), zeroBalance(api), zeroBalance(api)]]
|
||||
])
|
||||
);
|
||||
}
|
||||
@@ -71,6 +86,7 @@ function queryBalancesAccount (api: ApiInterfaceRx, accountId: AccountId, module
|
||||
const extract = (data: AccountData[]) =>
|
||||
data.map(({ feeFrozen, free, miscFrozen, reserved }): BalanceResult => [free, reserved, feeFrozen, miscFrozen]);
|
||||
|
||||
// NOTE this is for the first case where we do have instances specified
|
||||
return isFunction(api.query.system.account)
|
||||
? api.queryMulti<[AccountInfo, ...(AccountData[])]>([[api.query.system.account, accountId], ...balances]).pipe(
|
||||
map(([{ nonce }, ...balances]): Result => [nonce, extract(balances)])
|
||||
@@ -80,16 +96,27 @@ function queryBalancesAccount (api: ApiInterfaceRx, accountId: AccountId, module
|
||||
);
|
||||
}
|
||||
|
||||
function queryCurrent (api: ApiInterfaceRx, accountId: AccountId): Observable<Result> {
|
||||
function querySystemAccount (api: ApiInterfaceRx, accountId: AccountId): Observable<Result> {
|
||||
// AccountInfo is current, support old, eg. Edgeware
|
||||
return api.query.system.account<AccountInfo | ITuple<[Index, AccountData]>>(accountId).pipe(
|
||||
map((infoOrTuple): Result => {
|
||||
const { feeFrozen, free, miscFrozen, reserved } = (infoOrTuple as AccountInfo).nonce
|
||||
const data = (infoOrTuple as AccountInfo).nonce
|
||||
? (infoOrTuple as AccountInfo).data
|
||||
: (infoOrTuple as [Index, AccountData])[1];
|
||||
|
||||
const nonce = (infoOrTuple as AccountInfo).nonce || (infoOrTuple as [Index, AccountData])[0];
|
||||
|
||||
if (!data || data.isEmpty) {
|
||||
return [
|
||||
nonce,
|
||||
[[zeroBalance(api), zeroBalance(api), zeroBalance(api), zeroBalance(api)]]
|
||||
];
|
||||
}
|
||||
|
||||
const { feeFrozen, free, miscFrozen, reserved } = data;
|
||||
|
||||
return [
|
||||
(infoOrTuple as AccountInfo).nonce || (infoOrTuple as [Index, AccountData])[0],
|
||||
nonce,
|
||||
[[free, reserved, feeFrozen, miscFrozen]]
|
||||
];
|
||||
})
|
||||
@@ -113,6 +140,10 @@ function queryCurrent (api: ApiInterfaceRx, accountId: AccountId): Observable<Re
|
||||
*/
|
||||
export function account (instanceId: string, api: ApiInterfaceRx): (address: AccountIndex | AccountId | Address | string) => Observable<DeriveBalancesAccount> {
|
||||
const balanceInstances = api.registry.getModuleInstances(api.runtimeVersion.specName.toString(), 'balances');
|
||||
const empty: Result = [
|
||||
api.registry.createType('Index'),
|
||||
[[zeroBalance(api), zeroBalance(api), zeroBalance(api), zeroBalance(api)]]
|
||||
];
|
||||
|
||||
return memo(instanceId, (address: AccountIndex | AccountId | Address | string): Observable<DeriveBalancesAccount> =>
|
||||
api.derive.accounts.accountId(address).pipe(
|
||||
@@ -122,19 +153,17 @@ export function account (instanceId: string, api: ApiInterfaceRx): (address: Acc
|
||||
of(accountId),
|
||||
balanceInstances
|
||||
? queryBalancesAccount(api, accountId, balanceInstances)
|
||||
: isFunction(api.query.system.account)
|
||||
? queryCurrent(api, accountId)
|
||||
: isFunction(api.query.balances.account)
|
||||
: isFunction(api.query.system?.account)
|
||||
? querySystemAccount(api, accountId)
|
||||
: isFunction(api.query.balances?.account)
|
||||
? queryBalancesAccount(api, accountId)
|
||||
: queryBalancesFree(api, accountId)
|
||||
])
|
||||
: of([
|
||||
api.registry.createType('AccountId'),
|
||||
[
|
||||
api.registry.createType('Index'),
|
||||
[[api.registry.createType('Balance'), api.registry.createType('Balance'), api.registry.createType('Balance'), api.registry.createType('Balance')]]
|
||||
]
|
||||
: isFunction(api.query.balances?.freeBalance)
|
||||
? queryBalancesFree(api, accountId)
|
||||
: isFunction(api.query.system?.accountNonce)
|
||||
? querySystemNonce(api, accountId)
|
||||
: of(empty)
|
||||
])
|
||||
: of([api.registry.createType('AccountId'), empty])
|
||||
)
|
||||
),
|
||||
map((result): DeriveBalancesAccount => calcBalances(api, result))
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api-derive', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/api-derive', version: '4.15.1' };
|
||||
|
||||
@@ -120,8 +120,6 @@ function filterRewards (eras: EraIndex[], valInfo: [string, DeriveStakingQuery][
|
||||
return false;
|
||||
}
|
||||
|
||||
reward.isStakerPayout = true;
|
||||
|
||||
removeClaimed(validators, queryValidators, reward);
|
||||
|
||||
return true;
|
||||
|
||||
@@ -81,7 +81,6 @@ export interface DeriveStakerRewardValidator {
|
||||
export interface DeriveStakerReward {
|
||||
era: EraIndex;
|
||||
eraReward: Balance;
|
||||
isStakerPayout?: boolean;
|
||||
isEmpty: boolean;
|
||||
isValidator: boolean;
|
||||
nominating: DeriveEraExposureNominating[];
|
||||
|
||||
+11
-11
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Promise and RxJS wrappers around the Polkadot JS RPC",
|
||||
"main": "index.js",
|
||||
@@ -20,16 +20,16 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/api-derive": "4.14.1",
|
||||
"@polkadot/keyring": "^6.8.1",
|
||||
"@polkadot/metadata": "4.14.1",
|
||||
"@polkadot/rpc-core": "4.14.1",
|
||||
"@polkadot/rpc-provider": "4.14.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/types-known": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/util-crypto": "^6.8.1",
|
||||
"@polkadot/x-rxjs": "^6.8.1",
|
||||
"@polkadot/api-derive": "4.15.1",
|
||||
"@polkadot/keyring": "^6.9.1",
|
||||
"@polkadot/metadata": "4.15.1",
|
||||
"@polkadot/rpc-core": "4.15.1",
|
||||
"@polkadot/rpc-provider": "4.15.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/types-known": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/util-crypto": "^6.9.1",
|
||||
"@polkadot/x-rxjs": "^6.9.1",
|
||||
"eventemitter3": "^4.0.7"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// Auto-generated via `yarn polkadot-types-from-chain`, do not edit
|
||||
/* eslint-disable */
|
||||
|
||||
import type { Vec, u16, u32, u64, u8 } from '@polkadot/types';
|
||||
import type { Vec, u16, u32, u64 } from '@polkadot/types';
|
||||
import type { Codec } from '@polkadot/types/types';
|
||||
import type { Schedule } from '@polkadot/types/interfaces/contracts';
|
||||
import type { Balance, BalanceOf, BlockNumber, LockIdentifier, Moment, PalletId, Perbill, Percent, Permill, RuntimeDbWeight, Weight } from '@polkadot/types/interfaces/runtime';
|
||||
@@ -508,9 +508,6 @@ declare module '@polkadot/api/types/consts' {
|
||||
* Number of eras that staked funds must remain bonded for.
|
||||
**/
|
||||
bondingDuration: EraIndex & AugmentedConst<ApiType>;
|
||||
/**
|
||||
* Maximum number of nominations per nominator.
|
||||
**/
|
||||
maxNominations: u32 & AugmentedConst<ApiType>;
|
||||
/**
|
||||
* The maximum number of nominators rewarded for each validator.
|
||||
@@ -526,9 +523,8 @@ declare module '@polkadot/api/types/consts' {
|
||||
/**
|
||||
* Number of eras that slashes are deferred by, after computation.
|
||||
*
|
||||
* This should be less than the bonding duration.
|
||||
* Set to 0 if slashes should be applied immediately, without opportunity for
|
||||
* intervention.
|
||||
* This should be less than the bonding duration. Set to 0 if slashes
|
||||
* should be applied immediately, without opportunity for intervention.
|
||||
**/
|
||||
slashDeferDuration: EraIndex & AugmentedConst<ApiType>;
|
||||
/**
|
||||
@@ -560,7 +556,7 @@ declare module '@polkadot/api/types/consts' {
|
||||
* that the runtime should know about the prefix in order to make use of it as
|
||||
* an identifier of the chain.
|
||||
**/
|
||||
ss58Prefix: u8 & AugmentedConst<ApiType>;
|
||||
ss58Prefix: u16 & AugmentedConst<ApiType>;
|
||||
/**
|
||||
* Get the chain's current version.
|
||||
**/
|
||||
|
||||
@@ -256,9 +256,9 @@ declare module '@polkadot/api/types/errors' {
|
||||
**/
|
||||
DuplicateTopics: AugmentedError<ApiType>;
|
||||
/**
|
||||
* `seal_input` was called twice from the same contract execution context.
|
||||
* `seal_call` forwarded this contracts input. It therefore is no longer available.
|
||||
**/
|
||||
InputAlreadyRead: AugmentedError<ApiType>;
|
||||
InputForwarded: AugmentedError<ApiType>;
|
||||
/**
|
||||
* An origin TrieId written in the current block.
|
||||
**/
|
||||
@@ -316,9 +316,7 @@ declare module '@polkadot/api/types/errors' {
|
||||
**/
|
||||
RandomSubjectTooLong: AugmentedError<ApiType>;
|
||||
/**
|
||||
* The action performed is not allowed while the contract performing it is already
|
||||
* on the call stack. Those actions are contract self destruction and restoration
|
||||
* of a tombstone.
|
||||
* A call tried to invoke a contract that is flagged as non-reentrant.
|
||||
**/
|
||||
ReentranceDenied: AugmentedError<ApiType>;
|
||||
/**
|
||||
@@ -343,6 +341,11 @@ declare module '@polkadot/api/types/errors' {
|
||||
* This can be triggered by a call to `seal_terminate` or `seal_restore_to`.
|
||||
**/
|
||||
TerminatedInConstructor: AugmentedError<ApiType>;
|
||||
/**
|
||||
* Termination of a contract is not allowed while the contract is already
|
||||
* on the call stack. Can be triggered by `seal_terminate` or `seal_restore_to.
|
||||
**/
|
||||
TerminatedWhileReentrant: AugmentedError<ApiType>;
|
||||
/**
|
||||
* The amount of topics passed to `seal_deposit_events` exceeds the limit.
|
||||
**/
|
||||
|
||||
@@ -106,6 +106,10 @@ declare module '@polkadot/rpc-core/types.jsonrpc' {
|
||||
* Returns the keys with prefix from a child storage, leave empty to get all the keys
|
||||
**/
|
||||
getKeys: AugmentedRpc<(childKey: PrefixedStorageKey | string | Uint8Array, prefix: StorageKey | string | Uint8Array | any, at?: Hash | string | Uint8Array) => Observable<Vec<StorageKey>>>;
|
||||
/**
|
||||
* Returns the keys with prefix from a child storage with pagination support
|
||||
**/
|
||||
getKeysPaged: AugmentedRpc<(childKey: PrefixedStorageKey | string | Uint8Array, prefix: StorageKey | string | Uint8Array | any, count: u32 | AnyNumber | Uint8Array, startKey?: StorageKey | string | Uint8Array | any, at?: Hash | string | Uint8Array) => Observable<Vec<StorageKey>>>;
|
||||
/**
|
||||
* Returns a child storage entry at a specific block state
|
||||
**/
|
||||
|
||||
@@ -134,6 +134,10 @@ declare module '@polkadot/api/types/submittable' {
|
||||
*
|
||||
* Emits `Destroyed` event when successful.
|
||||
*
|
||||
* NOTE: It can be helpful to first freeze an asset before destroying it so that you
|
||||
* can provide accurate witness information and prevent users from manipulating state
|
||||
* in a way that can make it harder to destroy.
|
||||
*
|
||||
* Weight: `O(c + p + a)` where:
|
||||
* - `c = (witness.accounts - witness.sufficients)`
|
||||
* - `s = witness.sufficients`
|
||||
@@ -538,6 +542,27 @@ declare module '@polkadot/api/types/submittable' {
|
||||
* # </weight>
|
||||
**/
|
||||
transfer: AugmentedSubmittable<(dest: LookupSource | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, value: Compact<Balance> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [LookupSource, Compact<Balance>]>;
|
||||
/**
|
||||
* Transfer the entire transferable balance from the caller account.
|
||||
*
|
||||
* NOTE: This function only attempts to transfer _transferable_ balances. This means that
|
||||
* any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be
|
||||
* transferred by this function. To ensure that this function results in a killed account,
|
||||
* you might need to prepare the account by removing any reference counters, storage
|
||||
* deposits, etc...
|
||||
*
|
||||
* The dispatch origin of this call must be Signed.
|
||||
*
|
||||
* - `dest`: The recipient of the transfer.
|
||||
* - `keep_alive`: A boolean to determine if the `transfer_all` operation should send all
|
||||
* of the funds the account has, causing the sender account to be killed (false), or
|
||||
* transfer everything except at least the existential deposit, which will guarantee to
|
||||
* keep the sender account alive (true).
|
||||
* # <weight>
|
||||
* - O(1). Just like transfer, but reading the user's transferable balance first.
|
||||
* #</weight>
|
||||
**/
|
||||
transferAll: AugmentedSubmittable<(dest: LookupSource | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, keepAlive: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [LookupSource, bool]>;
|
||||
/**
|
||||
* Same as the [`transfer`] call, but with a check that the transfer will not kill the
|
||||
* origin account.
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/api', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/metadata",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Helpers to extract information from runtime metadata",
|
||||
"main": "index.js",
|
||||
@@ -20,12 +20,12 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/type-metadata#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/types-known": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/util-crypto": "^6.8.1"
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/types-known": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/util-crypto": "^6.9.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^6.8.1"
|
||||
"@polkadot/keyring": "^6.9.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/metadata', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/metadata', version: '4.15.1' };
|
||||
|
||||
@@ -506,8 +506,8 @@
|
||||
},
|
||||
{
|
||||
"name": "SS58Prefix",
|
||||
"type": "u8",
|
||||
"value": "0x2a",
|
||||
"type": "u16",
|
||||
"value": "0x2a00",
|
||||
"documentation": [
|
||||
" The designated SS85 prefix of this chain.",
|
||||
"",
|
||||
@@ -1638,6 +1638,39 @@
|
||||
" - DB Weight: 1 Read and 1 Write to dest (sender is in overlay already)",
|
||||
" #</weight>"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "transfer_all",
|
||||
"args": [
|
||||
{
|
||||
"name": "dest",
|
||||
"type": "LookupSource"
|
||||
},
|
||||
{
|
||||
"name": "keep_alive",
|
||||
"type": "bool"
|
||||
}
|
||||
],
|
||||
"documentation": [
|
||||
" Transfer the entire transferable balance from the caller account.",
|
||||
"",
|
||||
" NOTE: This function only attempts to transfer _transferable_ balances. This means that",
|
||||
" any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be",
|
||||
" transferred by this function. To ensure that this function results in a killed account,",
|
||||
" you might need to prepare the account by removing any reference counters, storage",
|
||||
" deposits, etc...",
|
||||
"",
|
||||
" The dispatch origin of this call must be Signed.",
|
||||
"",
|
||||
" - `dest`: The recipient of the transfer.",
|
||||
" - `keep_alive`: A boolean to determine if the `transfer_all` operation should send all",
|
||||
" of the funds the account has, causing the sender account to be killed (false), or",
|
||||
" transfer everything except at least the existential deposit, which will guarantee to",
|
||||
" keep the sender account alive (true).",
|
||||
" # <weight>",
|
||||
" - O(1). Just like transfer, but reading the user's transferable balance first.",
|
||||
" #</weight>"
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -3336,9 +3369,8 @@
|
||||
"documentation": [
|
||||
" Number of eras that slashes are deferred by, after computation.",
|
||||
"",
|
||||
" This should be less than the bonding duration.",
|
||||
" Set to 0 if slashes should be applied immediately, without opportunity for",
|
||||
" intervention."
|
||||
" This should be less than the bonding duration. Set to 0 if slashes",
|
||||
" should be applied immediately, without opportunity for intervention."
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -3356,9 +3388,7 @@
|
||||
"name": "MaxNominations",
|
||||
"type": "u32",
|
||||
"value": "0x10000000",
|
||||
"documentation": [
|
||||
" Maximum number of nominations per nominator."
|
||||
]
|
||||
"documentation": []
|
||||
}
|
||||
],
|
||||
"errors": [
|
||||
@@ -7561,17 +7591,16 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "ReentranceDenied",
|
||||
"name": "TerminatedWhileReentrant",
|
||||
"documentation": [
|
||||
" The action performed is not allowed while the contract performing it is already",
|
||||
" on the call stack. Those actions are contract self destruction and restoration",
|
||||
" of a tombstone."
|
||||
" Termination of a contract is not allowed while the contract is already",
|
||||
" on the call stack. Can be triggered by `seal_terminate` or `seal_restore_to."
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "InputAlreadyRead",
|
||||
"name": "InputForwarded",
|
||||
"documentation": [
|
||||
" `seal_input` was called twice from the same contract execution context."
|
||||
" `seal_call` forwarded this contracts input. It therefore is no longer available."
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -7647,6 +7676,12 @@
|
||||
"documentation": [
|
||||
" The debug message specified to `seal_debug_message` does contain invalid UTF-8."
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "ReentranceDenied",
|
||||
"documentation": [
|
||||
" A call tried to invoke a contract that is flagged as non-reentrant."
|
||||
]
|
||||
}
|
||||
],
|
||||
"index": 18
|
||||
@@ -12825,6 +12860,10 @@
|
||||
"",
|
||||
" Emits `Destroyed` event when successful.",
|
||||
"",
|
||||
" NOTE: It can be helpful to first freeze an asset before destroying it so that you",
|
||||
" can provide accurate witness information and prevent users from manipulating state",
|
||||
" in a way that can make it harder to destroy.",
|
||||
"",
|
||||
" Weight: `O(c + p + a)` where:",
|
||||
" - `c = (witness.accounts - witness.sufficients)`",
|
||||
" - `s = witness.sufficients`",
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -13,10 +13,13 @@ import { stringCamelCase } from '@polkadot/util';
|
||||
// in a pure Substrate/Polkadot implementation, any other custom origins won't be handled at all
|
||||
const KNOWN_ORIGINS: Record<string, string> = {
|
||||
/* eslint-disable sort-keys */
|
||||
// Substrate/Polkadot
|
||||
// Substrate
|
||||
Council: 'CollectiveOrigin',
|
||||
System: 'SystemOrigin',
|
||||
TechnicalCommittee: 'CollectiveOrigin',
|
||||
// Polkadot
|
||||
Xcm: 'XcmOrigin',
|
||||
XcmPallet: 'XcmOrigin',
|
||||
// Acala
|
||||
Authority: 'AuthorityOrigin',
|
||||
GeneralCouncil: 'CollectiveOrigin'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/rpc-core",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "A JavaScript wrapper for the Polkadot JsonRPC interface",
|
||||
"main": "index.js",
|
||||
@@ -20,13 +20,13 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/rpc-core#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/metadata": "4.14.1",
|
||||
"@polkadot/rpc-provider": "4.14.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/x-rxjs": "^6.8.1"
|
||||
"@polkadot/metadata": "4.15.1",
|
||||
"@polkadot/rpc-provider": "4.15.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/x-rxjs": "^6.9.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^6.8.1"
|
||||
"@polkadot/keyring": "^6.9.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/rpc-core', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/rpc-core', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/rpc-provider",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Transport providers for the API",
|
||||
"main": "index.js",
|
||||
@@ -20,17 +20,17 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/rpc-provider#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/util-crypto": "^6.8.1",
|
||||
"@polkadot/x-fetch": "^6.8.1",
|
||||
"@polkadot/x-global": "^6.8.1",
|
||||
"@polkadot/x-ws": "^6.8.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/util-crypto": "^6.9.1",
|
||||
"@polkadot/x-fetch": "^6.9.1",
|
||||
"@polkadot/x-global": "^6.9.1",
|
||||
"@polkadot/x-ws": "^6.9.1",
|
||||
"eventemitter3": "^4.0.7"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^6.8.1",
|
||||
"@polkadot/metadata": "4.14.1",
|
||||
"@polkadot/keyring": "^6.9.1",
|
||||
"@polkadot/metadata": "4.15.1",
|
||||
"mock-socket": "^9.0.3",
|
||||
"nock": "^13.1.0"
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/rpc-provider', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/rpc-provider', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/typegen",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Type generation scripts",
|
||||
"main": "index.js",
|
||||
@@ -29,11 +29,11 @@
|
||||
"@babel/core": "^7.14.5",
|
||||
"@babel/register": "^7.14.5",
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/api": "4.14.1",
|
||||
"@polkadot/metadata": "4.14.1",
|
||||
"@polkadot/rpc-provider": "4.14.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/api": "4.15.1",
|
||||
"@polkadot/metadata": "4.15.1",
|
||||
"@polkadot/rpc-provider": "4.15.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"handlebars": "^4.7.7",
|
||||
"websocket": "^1.0.34",
|
||||
"yargs": "^17.0.1"
|
||||
|
||||
@@ -54,7 +54,7 @@ function documentationVecToMarkdown (docLines: Vec<Text>, indent = 0): string {
|
||||
? `${md}\n\n` // empty line
|
||||
: /^[*-]/.test(docLine.trimStart()) && !md.endsWith('\n\n')
|
||||
? `${md}\n\n${docLine}` // line calling for a preceding linebreak
|
||||
: `${md}${docLine.replace(/^#{1,3} /, '#### ')} `
|
||||
: `${md} ${docLine.replace(/^#{1,3} /, '#### ')} `
|
||||
, '')
|
||||
.replace(/#### <weight>/g, '<weight>')
|
||||
.replace(/<weight>(.|\n)*?<\/weight>/g, '')
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/typegen', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/typegen', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/types-known",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "A JavaScript wrapper for the Polkadot JsonRPC interface",
|
||||
"main": "index.js",
|
||||
@@ -20,8 +20,8 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/types-known#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/networks": "^6.8.1",
|
||||
"@polkadot/types": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1"
|
||||
"@polkadot/networks": "^6.9.1",
|
||||
"@polkadot/types": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,6 +17,9 @@ const typesModules: Record<string, OverrideModuleType> = {
|
||||
balances: {
|
||||
Status: 'BalanceStatus'
|
||||
},
|
||||
beefy: {
|
||||
AuthorityId: 'BeefyId'
|
||||
},
|
||||
contracts: {
|
||||
StorageKey: 'ContractStorageKey'
|
||||
},
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/types-known', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/types-known', version: '4.15.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/types",
|
||||
"version": "4.14.1",
|
||||
"version": "4.15.1",
|
||||
"type": "module",
|
||||
"description": "Implementation of the Parity codec",
|
||||
"main": "index.js",
|
||||
@@ -20,13 +20,13 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/types#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.5",
|
||||
"@polkadot/metadata": "4.14.1",
|
||||
"@polkadot/util": "^6.8.1",
|
||||
"@polkadot/util-crypto": "^6.8.1",
|
||||
"@polkadot/x-rxjs": "^6.8.1"
|
||||
"@polkadot/metadata": "4.15.1",
|
||||
"@polkadot/util": "^6.9.1",
|
||||
"@polkadot/util-crypto": "^6.9.1",
|
||||
"@polkadot/x-rxjs": "^6.9.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^6.8.1",
|
||||
"@polkadot/keyring": "^6.9.1",
|
||||
"@types/bn.js": "^4.11.6",
|
||||
"bn.js": "^4.11.9"
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ import type { ExtrinsicOrHash, ExtrinsicStatus } from '@polkadot/types/interface
|
||||
import type { UncleEntryItem } from '@polkadot/types/interfaces/authorship';
|
||||
import type { AllowedSlots, BabeAuthorityWeight, BabeBlockWeight, BabeEpochConfiguration, BabeEquivocationProof, BabeWeight, EpochAuthorship, MaybeRandomness, MaybeVrf, NextConfigDescriptor, NextConfigDescriptorV1, Randomness, RawBabePreDigest, RawBabePreDigestCompat, RawBabePreDigestPrimary, RawBabePreDigestPrimaryTo159, RawBabePreDigestSecondaryPlain, RawBabePreDigestSecondaryTo159, RawBabePreDigestSecondaryVRF, RawBabePreDigestTo159, SlotNumber, VrfData, VrfOutput, VrfProof } from '@polkadot/types/interfaces/babe';
|
||||
import type { AccountData, BalanceLock, BalanceLockTo212, BalanceStatus, Reasons, ReserveData, ReserveIdentifier, VestingSchedule, WithdrawReasons } from '@polkadot/types/interfaces/balances';
|
||||
import type { BeefyCommitment, BeefyNextAuthoritySet, BeefyPayload, BeefySignedCommitment, MmrRootHash, ValidatorSetId } from '@polkadot/types/interfaces/beefy';
|
||||
import type { BeefyCommitment, BeefyId, BeefyNextAuthoritySet, BeefyPayload, BeefySignedCommitment, MmrRootHash, ValidatorSetId } from '@polkadot/types/interfaces/beefy';
|
||||
import type { BridgedBlockHash, BridgedBlockNumber, BridgedHeader, InitializationData } from '@polkadot/types/interfaces/bridges';
|
||||
import type { BlockHash } from '@polkadot/types/interfaces/chain';
|
||||
import type { PrefixedStorageKey } from '@polkadot/types/interfaces/childstate';
|
||||
@@ -57,7 +57,7 @@ import type { Multiplier } from '@polkadot/types/interfaces/txpayment';
|
||||
import type { ClassDetails, ClassId, ClassMetadata, DepositBalance, DepositBalanceOf, DestroyWitness, InstanceDetails, InstanceId, InstanceMetadata } from '@polkadot/types/interfaces/uniques';
|
||||
import type { Multisig, Timepoint } from '@polkadot/types/interfaces/utility';
|
||||
import type { VestingInfo } from '@polkadot/types/interfaces/vesting';
|
||||
import type { AccountId32Junction, AccountIndex64Junction, AccountKey20Junction, AssetInstance, BodyId, BodyPart, BodyPartAtLeastProportion, BodyPartFraction, BodyPartMoreThanProportion, DoubleEncodedCall, InboundStatus, Junction, MultiAsset, MultiAssetAbstractFungible, MultiAssetAbstractNonFungible, MultiAssetConcreteFungible, MultiAssetConcreteNonFungible, MultiLocation, NetworkId, OutboundStatus, Outcome, PluralityJunction, QueueConfigData, VersionedMultiAsset, VersionedMultiLocation, VersionedXcm, Xcm, XcmAssetEffects, XcmError, XcmHrmpChannelAccepted, XcmHrmpChannelClosing, XcmHrmpNewChannelOpenRequest, XcmOrder, XcmOrderBuyExecution, XcmOrderDepositAsset, XcmOrderDepositReserveAsset, XcmOrderExchangeAsset, XcmOrderInitiateReserveWithdraw, XcmOrderInitiateTeleport, XcmOrderQueryHolding, XcmOriginKind, XcmQueryResponse, XcmRelayedFrom, XcmReserveAssetDeposit, XcmResponse, XcmTeleportAsset, XcmTransact, XcmTransferAsset, XcmTransferReserveAsset, XcmWithdrawAsset, XcmpMessageFormat } from '@polkadot/types/interfaces/xcm';
|
||||
import type { AccountId32Junction, AccountIndex64Junction, AccountKey20Junction, AssetInstance, BodyId, BodyPart, BodyPartAtLeastProportion, BodyPartFraction, BodyPartMoreThanProportion, DoubleEncodedCall, InboundStatus, Junction, MultiAsset, MultiAssetAbstractFungible, MultiAssetAbstractNonFungible, MultiAssetConcreteFungible, MultiAssetConcreteNonFungible, MultiLocation, NetworkId, OutboundStatus, Outcome, PluralityJunction, QueueConfigData, VersionedMultiAsset, VersionedMultiLocation, VersionedXcm, Xcm, XcmAssetEffects, XcmError, XcmHrmpChannelAccepted, XcmHrmpChannelClosing, XcmHrmpNewChannelOpenRequest, XcmOrder, XcmOrderBuyExecution, XcmOrderDepositAsset, XcmOrderDepositReserveAsset, XcmOrderExchangeAsset, XcmOrderInitiateReserveWithdraw, XcmOrderInitiateTeleport, XcmOrderQueryHolding, XcmOrigin, XcmOriginKind, XcmQueryResponse, XcmRelayedFrom, XcmReserveAssetDeposit, XcmResponse, XcmTeleportAsset, XcmTransact, XcmTransferAsset, XcmTransferReserveAsset, XcmWithdrawAsset, XcmpMessageFormat } from '@polkadot/types/interfaces/xcm';
|
||||
|
||||
declare module '@polkadot/types/types/registry' {
|
||||
export interface InterfaceTypes {
|
||||
@@ -226,6 +226,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
'Option<BalanceOf>': Option<BalanceOf>;
|
||||
'Option<BalanceStatus>': Option<BalanceStatus>;
|
||||
'Option<BeefyCommitment>': Option<BeefyCommitment>;
|
||||
'Option<BeefyId>': Option<BeefyId>;
|
||||
'Option<BeefyKey>': Option<BeefyKey>;
|
||||
'Option<BeefyNextAuthoritySet>': Option<BeefyNextAuthoritySet>;
|
||||
'Option<BeefyPayload>': Option<BeefyPayload>;
|
||||
@@ -1018,6 +1019,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
'Option<XcmOrderInitiateReserveWithdraw>': Option<XcmOrderInitiateReserveWithdraw>;
|
||||
'Option<XcmOrderInitiateTeleport>': Option<XcmOrderInitiateTeleport>;
|
||||
'Option<XcmOrderQueryHolding>': Option<XcmOrderQueryHolding>;
|
||||
'Option<XcmOrigin>': Option<XcmOrigin>;
|
||||
'Option<XcmOriginKind>': Option<XcmOriginKind>;
|
||||
'Option<XcmpMessageFormat>': Option<XcmpMessageFormat>;
|
||||
'Option<XcmQueryResponse>': Option<XcmQueryResponse>;
|
||||
@@ -1100,6 +1102,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
'Vec<BalanceOf>': Vec<BalanceOf>;
|
||||
'Vec<BalanceStatus>': Vec<BalanceStatus>;
|
||||
'Vec<BeefyCommitment>': Vec<BeefyCommitment>;
|
||||
'Vec<BeefyId>': Vec<BeefyId>;
|
||||
'Vec<BeefyKey>': Vec<BeefyKey>;
|
||||
'Vec<BeefyNextAuthoritySet>': Vec<BeefyNextAuthoritySet>;
|
||||
'Vec<BeefyPayload>': Vec<BeefyPayload>;
|
||||
@@ -1892,6 +1895,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
'Vec<XcmOrderInitiateReserveWithdraw>': Vec<XcmOrderInitiateReserveWithdraw>;
|
||||
'Vec<XcmOrderInitiateTeleport>': Vec<XcmOrderInitiateTeleport>;
|
||||
'Vec<XcmOrderQueryHolding>': Vec<XcmOrderQueryHolding>;
|
||||
'Vec<XcmOrigin>': Vec<XcmOrigin>;
|
||||
'Vec<XcmOriginKind>': Vec<XcmOriginKind>;
|
||||
'Vec<XcmpMessageFormat>': Vec<XcmpMessageFormat>;
|
||||
'Vec<XcmQueryResponse>': Vec<XcmQueryResponse>;
|
||||
@@ -1974,6 +1978,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
BalanceOf: BalanceOf;
|
||||
BalanceStatus: BalanceStatus;
|
||||
BeefyCommitment: BeefyCommitment;
|
||||
BeefyId: BeefyId;
|
||||
BeefyKey: BeefyKey;
|
||||
BeefyNextAuthoritySet: BeefyNextAuthoritySet;
|
||||
BeefyPayload: BeefyPayload;
|
||||
@@ -2766,6 +2771,7 @@ declare module '@polkadot/types/types/registry' {
|
||||
XcmOrderInitiateReserveWithdraw: XcmOrderInitiateReserveWithdraw;
|
||||
XcmOrderInitiateTeleport: XcmOrderInitiateTeleport;
|
||||
XcmOrderQueryHolding: XcmOrderQueryHolding;
|
||||
XcmOrigin: XcmOrigin;
|
||||
XcmOriginKind: XcmOriginKind;
|
||||
XcmpMessageFormat: XcmpMessageFormat;
|
||||
XcmQueryResponse: XcmQueryResponse;
|
||||
|
||||
@@ -252,28 +252,254 @@ describe('getTypeDef', (): void => {
|
||||
});
|
||||
});
|
||||
|
||||
// FIXME - not handled atm
|
||||
it.skip('creates a nested fixed vec', (): void => {
|
||||
it('creates a nested fixed vec', (): void => {
|
||||
expect(
|
||||
getTypeDef('[[u8;32];3]')
|
||||
getTypeDef('[[[bool; 3]; 6]; 9]')
|
||||
).toEqual({
|
||||
ext: {
|
||||
length: 3,
|
||||
type: '[u8;32]'
|
||||
},
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 9,
|
||||
sub: {
|
||||
ext: {
|
||||
length: 32
|
||||
},
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 6,
|
||||
sub: {
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 3,
|
||||
sub: {
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'bool'
|
||||
},
|
||||
type: '[bool;3]'
|
||||
},
|
||||
type: '[[bool;3];6]'
|
||||
},
|
||||
type: '[[[bool;3];6];9]'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a nested fixed vec (named)', (): void => {
|
||||
expect(
|
||||
getTypeDef('[[bool; 6]; 3; MyType]')
|
||||
).toEqual({
|
||||
displayName: 'MyType',
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 3,
|
||||
sub: {
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 6,
|
||||
sub: {
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u8'
|
||||
type: 'bool'
|
||||
},
|
||||
type: '[u8;32]'
|
||||
type: '[bool;6]'
|
||||
},
|
||||
type: '[[u8;32];3]'
|
||||
type: '[[bool;6];3;MyType]'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a nested tuple', (): void => {
|
||||
expect(
|
||||
getTypeDef('((u32, u64), u128)')
|
||||
).toEqual({
|
||||
info: TypeDefInfo.Tuple,
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Tuple,
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u64'
|
||||
}
|
||||
],
|
||||
type: '(u32,u64)'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u128'
|
||||
}
|
||||
],
|
||||
type: '((u32,u64),u128)'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a nested enum with tuple/struct', (): void => {
|
||||
expect(
|
||||
getTypeDef(JSON.stringify({
|
||||
_enum: {
|
||||
A: 'u32',
|
||||
B: '(u32, bool)',
|
||||
C: {
|
||||
d: 'AccountId',
|
||||
e: 'Balance'
|
||||
}
|
||||
}
|
||||
}))
|
||||
).toEqual({
|
||||
info: TypeDefInfo.Enum,
|
||||
sub: [
|
||||
{
|
||||
index: 0,
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'A',
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
index: 1,
|
||||
info: TypeDefInfo.Tuple,
|
||||
name: 'B',
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'bool'
|
||||
}
|
||||
],
|
||||
type: '(u32,bool)'
|
||||
},
|
||||
{
|
||||
index: 2,
|
||||
info: TypeDefInfo.Struct,
|
||||
name: 'C',
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'd',
|
||||
type: 'AccountId'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'e',
|
||||
type: 'Balance'
|
||||
}
|
||||
],
|
||||
type: '{"d":"AccountId","e":"Balance"}'
|
||||
}
|
||||
],
|
||||
type: '{"_enum":{"A":"u32","B":"(u32,bool)","C":{"d":"AccountId","e":"Balance"}}}'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a nested struct with struct/tuple', (): void => {
|
||||
expect(
|
||||
getTypeDef(JSON.stringify({
|
||||
a: 'u32',
|
||||
b: '(u32, bool)',
|
||||
c: {
|
||||
d: 'AccountId',
|
||||
e: 'Balance'
|
||||
}
|
||||
}))
|
||||
).toEqual({
|
||||
info: TypeDefInfo.Struct,
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'a',
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Tuple,
|
||||
name: 'b',
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'bool'
|
||||
}
|
||||
],
|
||||
type: '(u32,bool)'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Struct,
|
||||
name: 'c',
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'd',
|
||||
type: 'AccountId'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'e',
|
||||
type: 'Balance'
|
||||
}
|
||||
],
|
||||
type: '{"d":"AccountId","e":"Balance"}'
|
||||
}
|
||||
],
|
||||
type: '{"a":"u32","b":"(u32,bool)","c":{"d":"AccountId","e":"Balance"}}'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a Vec with nested fixed', (): void => {
|
||||
expect(
|
||||
getTypeDef('Vec<[[[bool; 3]; 6]; 9]>')
|
||||
).toEqual({
|
||||
info: TypeDefInfo.Vec,
|
||||
sub: {
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 9,
|
||||
sub: {
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 6,
|
||||
sub: {
|
||||
info: TypeDefInfo.VecFixed,
|
||||
length: 3,
|
||||
sub: {
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'bool'
|
||||
},
|
||||
type: '[bool;3]'
|
||||
},
|
||||
type: '[[bool;3];6]'
|
||||
},
|
||||
type: '[[[bool;3];6];9]'
|
||||
},
|
||||
type: 'Vec<[[[bool;3];6];9]>'
|
||||
});
|
||||
});
|
||||
|
||||
it('creates a Vec with nested struct', (): void => {
|
||||
expect(
|
||||
getTypeDef('Vec<{ "a": "u32", "b": "(u32, bool)" }>')
|
||||
).toEqual({
|
||||
info: TypeDefInfo.Vec,
|
||||
sub: {
|
||||
info: TypeDefInfo.Struct,
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
name: 'a',
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Tuple,
|
||||
name: 'b',
|
||||
sub: [
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
info: TypeDefInfo.Plain,
|
||||
type: 'bool'
|
||||
}
|
||||
],
|
||||
type: '(u32,bool)'
|
||||
}
|
||||
],
|
||||
type: '{"a":"u32","b":"(u32,bool)"}'
|
||||
},
|
||||
type: 'Vec<{"a":"u32","b":"(u32,bool)"}>'
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
import type { TypeDef } from './types';
|
||||
|
||||
import { assert, isNumber } from '@polkadot/util';
|
||||
import { assert, isNumber, isString } from '@polkadot/util';
|
||||
|
||||
import { sanitize } from './sanitize';
|
||||
import { TypeDefInfo } from './types';
|
||||
@@ -16,6 +16,12 @@ interface TypeDefOptions {
|
||||
|
||||
const MAX_NESTED = 64;
|
||||
|
||||
function getTypeString (typeOrObj: any): string {
|
||||
return isString(typeOrObj)
|
||||
? typeOrObj.toString()
|
||||
: JSON.stringify(typeOrObj);
|
||||
}
|
||||
|
||||
function isRustEnum (details: Record<string, string> | Record<string, number>): details is Record<string, string> {
|
||||
const values = Object.values(details);
|
||||
|
||||
@@ -44,9 +50,8 @@ function _decodeEnum (value: TypeDef, details: string[] | Record<string, string>
|
||||
type: 'Null'
|
||||
}));
|
||||
} else if (isRustEnum(details)) {
|
||||
value.sub = Object.entries(details).map(([name, type], index): TypeDef => ({
|
||||
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
||||
...getTypeDef(type || 'Null', { name }, count),
|
||||
value.sub = Object.entries(details).map(([name, typeOrObj], index): TypeDef => ({
|
||||
...getTypeDef(getTypeString(typeOrObj || 'Null'), { name }, count),
|
||||
index
|
||||
}));
|
||||
} else {
|
||||
@@ -96,8 +101,7 @@ function _decodeStruct (value: TypeDef, type: string, _: string, count: number):
|
||||
? new Map(Object.entries(parsed._alias))
|
||||
: undefined;
|
||||
value.sub = keys.filter((name) => !['_alias'].includes(name)).map((name): TypeDef =>
|
||||
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
||||
getTypeDef(parsed[name], { name }, count)
|
||||
getTypeDef(getTypeString(parsed[name]), { name }, count)
|
||||
);
|
||||
|
||||
return value;
|
||||
@@ -106,7 +110,24 @@ function _decodeStruct (value: TypeDef, type: string, _: string, count: number):
|
||||
// decode a fixed vector, e.g. [u8;32]
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
function _decodeFixedVec (value: TypeDef, type: string, _: string, count: number): TypeDef {
|
||||
const [vecType, strLength, displayName] = type.substr(1, type.length - 2).split(';');
|
||||
const max = type.length - 1;
|
||||
let index = -1;
|
||||
let inner = 0;
|
||||
|
||||
for (let i = 1; (i < max) && (index === -1); i++) {
|
||||
if (type[i] === ';' && inner === 0) {
|
||||
index = i;
|
||||
} else if (['[', '(', '<'].includes(type[i])) {
|
||||
inner++;
|
||||
} else if ([']', ')', '>'].includes(type[i])) {
|
||||
inner--;
|
||||
}
|
||||
}
|
||||
|
||||
assert(index !== -1, () => `${type}: Unable to extract location of ';'`);
|
||||
|
||||
const vecType = type.substr(1, index - 1);
|
||||
const [strLength, displayName] = type.substr(index + 1, max - index - 1).split(';');
|
||||
const length = parseInt(strLength.trim(), 10);
|
||||
|
||||
// as a first round, only u8 via u8aFixed, we can add more support
|
||||
@@ -114,7 +135,6 @@ function _decodeFixedVec (value: TypeDef, type: string, _: string, count: number
|
||||
|
||||
value.displayName = displayName;
|
||||
value.length = length;
|
||||
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
||||
value.sub = getTypeDef(vecType, {}, count);
|
||||
|
||||
return value;
|
||||
@@ -124,7 +144,6 @@ function _decodeFixedVec (value: TypeDef, type: string, _: string, count: number
|
||||
function _decodeTuple (value: TypeDef, _: string, subType: string, count: number): TypeDef {
|
||||
value.sub = subType.length === 0
|
||||
? []
|
||||
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
||||
: typeSplit(subType).map((inner) => getTypeDef(inner, {}, count));
|
||||
|
||||
return value;
|
||||
|
||||
@@ -15,7 +15,7 @@ import { blake2AsU8a } from '@polkadot/util-crypto';
|
||||
|
||||
import { Json } from '../codec/Json';
|
||||
import { Raw } from '../codec/Raw';
|
||||
import { defaultExtensions, expandExtensionTypes, findUnknownExtensions } from '../extrinsic/signedExtensions';
|
||||
import { expandExtensionTypes, fallbackExtensions, findUnknownExtensions } from '../extrinsic/signedExtensions';
|
||||
import { GenericEventData } from '../generic/Event';
|
||||
import * as baseTypes from '../index.types';
|
||||
import * as definitions from '../interfaces/definitions';
|
||||
@@ -132,7 +132,7 @@ export class TypeRegistry implements Registry {
|
||||
|
||||
#knownTypes: RegisteredTypes = {};
|
||||
|
||||
#signedExtensions: string[] = defaultExtensions;
|
||||
#signedExtensions: string[] = fallbackExtensions;
|
||||
|
||||
#userExtensions?: ExtDef;
|
||||
|
||||
@@ -397,7 +397,7 @@ export class TypeRegistry implements Registry {
|
||||
signedExtensions || (
|
||||
metadata.asLatest.extrinsic.version.gt(BN_ZERO)
|
||||
? metadata.asLatest.extrinsic.signedExtensions.map((key) => key.toString())
|
||||
: defaultExtensions
|
||||
: fallbackExtensions
|
||||
),
|
||||
userExtensions
|
||||
);
|
||||
@@ -409,7 +409,7 @@ export class TypeRegistry implements Registry {
|
||||
}
|
||||
|
||||
// sets the available signed extensions
|
||||
setSignedExtensions (signedExtensions: string[] = defaultExtensions, userExtensions?: ExtDef): void {
|
||||
setSignedExtensions (signedExtensions: string[] = fallbackExtensions, userExtensions?: ExtDef): void {
|
||||
this.#signedExtensions = signedExtensions;
|
||||
this.#userExtensions = userExtensions;
|
||||
|
||||
|
||||
@@ -5,20 +5,25 @@ import type { ExtDef, ExtInfo, ExtTypes } from './types';
|
||||
|
||||
import { polkadot } from './polkadot';
|
||||
import { shell } from './shell';
|
||||
import { statemint } from './statemint';
|
||||
import { substrate } from './substrate';
|
||||
|
||||
// A mapping of the known signed extensions to the extra fields that they contain. Unlike in the actual extensions,
|
||||
// we define the extra fields not as a Tuple, but rather as a struct so they can be named. These will be expanded
|
||||
// into the various fields when added to the payload (we only support V4 onwards with these, V3 and earlier are
|
||||
// deemed fixed and non-changeable)
|
||||
const allExtensions: ExtDef = {
|
||||
export const allExtensions: ExtDef = {
|
||||
...substrate,
|
||||
...polkadot,
|
||||
...shell,
|
||||
...polkadot
|
||||
...statemint
|
||||
};
|
||||
|
||||
// the v4 signed extensions (the order is important here, as applied by default)
|
||||
const defaultExtensions: Array<keyof typeof allExtensions> = [
|
||||
// the v4 signed extensions prior to the point of exposing these to the metadata.
|
||||
// This may not match 100% with the current defaults and are used when not specified
|
||||
// in the metadata (which is for very old chains). The order is important here, as
|
||||
// applied by default
|
||||
export const fallbackExtensions: Array<keyof typeof allExtensions> = [
|
||||
'CheckVersion',
|
||||
'CheckGenesis',
|
||||
'CheckEra',
|
||||
@@ -28,18 +33,16 @@ const defaultExtensions: Array<keyof typeof allExtensions> = [
|
||||
'CheckBlockGasLimit'
|
||||
];
|
||||
|
||||
function findUnknownExtensions (extensions: string[], userExtensions: ExtDef = {}): string[] {
|
||||
export function findUnknownExtensions (extensions: string[], userExtensions: ExtDef = {}): string[] {
|
||||
const names = [...Object.keys(allExtensions), ...Object.keys(userExtensions)];
|
||||
|
||||
return extensions.filter((key) => !names.includes(key));
|
||||
}
|
||||
|
||||
function expandExtensionTypes (extensions: string[], type: keyof ExtInfo, userExtensions: ExtDef = {}): ExtTypes {
|
||||
export function expandExtensionTypes (extensions: string[], type: keyof ExtInfo, userExtensions: ExtDef = {}): ExtTypes {
|
||||
return extensions
|
||||
// Always allow user extensions first - these should provide overrides
|
||||
.map((key) => userExtensions[key] || allExtensions[key])
|
||||
.filter((info): info is ExtInfo => !!info)
|
||||
.reduce((result, info): ExtTypes => ({ ...result, ...info[type] }), {});
|
||||
}
|
||||
|
||||
export { allExtensions, defaultExtensions, expandExtensionTypes, findUnknownExtensions };
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
// Copyright 2017-2021 @polkadot/types authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
import type { ExtDef } from './types';
|
||||
|
||||
export const statemint: ExtDef = {
|
||||
ChargeAssetTxPayment: {
|
||||
extrinsic: {
|
||||
tip: 'Compact<Balance>',
|
||||
// eslint-disable-next-line sort-keys
|
||||
assetId: 'Option<AssetId>'
|
||||
},
|
||||
payload: {}
|
||||
}
|
||||
};
|
||||
@@ -11,5 +11,5 @@ export { GenericChainProperties } from './ChainProperties';
|
||||
export { GenericConsensusEngineId } from './ConsensusEngineId';
|
||||
export { GenericEvent, GenericEventData } from './Event';
|
||||
export { GenericLookupSource } from './LookupSource';
|
||||
export { GenericMultiAddress } from './MultiAddress';
|
||||
export { GenericMultiAddress, GenericMultiAddress as GenericAddress } from './MultiAddress';
|
||||
export { GenericVote } from './Vote';
|
||||
|
||||
@@ -25,6 +25,7 @@ export default {
|
||||
blockNumber: 'BlockNumber',
|
||||
validatorSetId: 'ValidatorSetId'
|
||||
},
|
||||
BeefyId: '[u8; 33]',
|
||||
BeefySignedCommitment: {
|
||||
commitment: 'BeefyCommitment',
|
||||
signatures: 'Vec<Option<Signature>>'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
|
||||
/* eslint-disable */
|
||||
|
||||
import type { Option, Struct, Vec, u32, u64 } from '@polkadot/types';
|
||||
import type { Option, Struct, U8aFixed, Vec, u32, u64 } from '@polkadot/types';
|
||||
import type { Signature } from '@polkadot/types/interfaces/extrinsics';
|
||||
import type { BlockNumber, H256 } from '@polkadot/types/interfaces/runtime';
|
||||
|
||||
@@ -12,6 +12,9 @@ export interface BeefyCommitment extends Struct {
|
||||
readonly validatorSetId: ValidatorSetId;
|
||||
}
|
||||
|
||||
/** @name BeefyId */
|
||||
export interface BeefyId extends U8aFixed {}
|
||||
|
||||
/** @name BeefyNextAuthoritySet */
|
||||
export interface BeefyNextAuthoritySet extends Struct {
|
||||
readonly id: u64;
|
||||
|
||||
@@ -28,6 +28,36 @@ export default {
|
||||
],
|
||||
type: 'Vec<StorageKey>'
|
||||
},
|
||||
getKeysPaged: {
|
||||
alias: ['childstate_getKeysPagedAt'],
|
||||
description: 'Returns the keys with prefix from a child storage with pagination support',
|
||||
params: [
|
||||
{
|
||||
name: 'childKey',
|
||||
type: 'PrefixedStorageKey'
|
||||
},
|
||||
{
|
||||
name: 'prefix',
|
||||
type: 'StorageKey'
|
||||
},
|
||||
{
|
||||
name: 'count',
|
||||
type: 'u32'
|
||||
},
|
||||
{
|
||||
name: 'startKey',
|
||||
type: 'StorageKey',
|
||||
isOptional: true
|
||||
},
|
||||
{
|
||||
name: 'at',
|
||||
type: 'Hash',
|
||||
isHistoric: true,
|
||||
isOptional: true
|
||||
}
|
||||
],
|
||||
type: 'Vec<StorageKey>'
|
||||
},
|
||||
getStorage: {
|
||||
description: 'Returns a child storage entry at a specific block state',
|
||||
params: [
|
||||
|
||||
@@ -22,6 +22,11 @@ const xcm = {
|
||||
XcmHrmpChannelAccepted: { recipient: 'Compact<u32>' },
|
||||
XcmHrmpChannelClosing: { initiator: 'Compact<u32>', sender: 'Compact<u32>', recipient: 'Compact<u32>' },
|
||||
XcmRelayedFrom: { who: 'MultiLocation', message: 'Xcm' },
|
||||
XcmOrigin: {
|
||||
_enum: {
|
||||
Xcm: 'MultiLocation'
|
||||
}
|
||||
},
|
||||
Xcm: {
|
||||
_enum: {
|
||||
WithdrawAsset: 'XcmWithdrawAsset',
|
||||
|
||||
@@ -403,6 +403,12 @@ export interface XcmOrderQueryHolding extends Struct {
|
||||
readonly assets: Vec<MultiAsset>;
|
||||
}
|
||||
|
||||
/** @name XcmOrigin */
|
||||
export interface XcmOrigin extends Enum {
|
||||
readonly isXcm: boolean;
|
||||
readonly asXcm: MultiLocation;
|
||||
}
|
||||
|
||||
/** @name XcmOriginKind */
|
||||
export interface XcmOriginKind extends Enum {
|
||||
readonly isNative: boolean;
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/types', version: '4.14.1' };
|
||||
export const packageInfo = { name: '@polkadot/types', version: '4.15.1' };
|
||||
|
||||
@@ -1849,44 +1849,44 @@ __metadata:
|
||||
resolution: "@polkadot/api-contract@workspace:packages/api-contract"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/api": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/x-rxjs": ^6.8.1
|
||||
"@polkadot/api": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/x-rxjs": ^6.9.1
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/api-derive@4.14.1, @polkadot/api-derive@workspace:packages/api-derive":
|
||||
"@polkadot/api-derive@4.15.1, @polkadot/api-derive@workspace:packages/api-derive":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/api-derive@workspace:packages/api-derive"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/api": 4.14.1
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/rpc-core": 4.14.1
|
||||
"@polkadot/rpc-provider": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/util-crypto": ^6.8.1
|
||||
"@polkadot/x-rxjs": ^6.8.1
|
||||
"@polkadot/api": 4.15.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/rpc-core": 4.15.1
|
||||
"@polkadot/rpc-provider": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/util-crypto": ^6.9.1
|
||||
"@polkadot/x-rxjs": ^6.9.1
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/api@4.14.1, @polkadot/api@workspace:packages/api":
|
||||
"@polkadot/api@4.15.1, @polkadot/api@workspace:packages/api":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/api@workspace:packages/api"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/api-derive": 4.14.1
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/metadata": 4.14.1
|
||||
"@polkadot/rpc-core": 4.14.1
|
||||
"@polkadot/rpc-provider": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/types-known": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/util-crypto": ^6.8.1
|
||||
"@polkadot/x-rxjs": ^6.8.1
|
||||
"@polkadot/api-derive": 4.15.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/metadata": 4.15.1
|
||||
"@polkadot/rpc-core": 4.15.1
|
||||
"@polkadot/rpc-provider": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/types-known": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/util-crypto": ^6.9.1
|
||||
"@polkadot/x-rxjs": ^6.9.1
|
||||
eventemitter3: ^4.0.7
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
@@ -1977,69 +1977,69 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/keyring@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/keyring@npm:6.8.1"
|
||||
"@polkadot/keyring@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/keyring@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/util": 6.8.1
|
||||
"@polkadot/util-crypto": 6.8.1
|
||||
"@polkadot/util": 6.9.1
|
||||
"@polkadot/util-crypto": 6.9.1
|
||||
peerDependencies:
|
||||
"@polkadot/util": 6.8.1
|
||||
"@polkadot/util-crypto": 6.8.1
|
||||
checksum: a7c10a9c2e2f32d4ba03333044ada16c431b9e5500d41df4e1e27eb369d259a501479c134f666667d0d6e0218cf8628447ac679a866df5fc2ea084943377b47a
|
||||
"@polkadot/util": 6.9.1
|
||||
"@polkadot/util-crypto": 6.9.1
|
||||
checksum: 7fd43ed3cd93b6e0ff650c1ceaa08e6dd93426b2c417cef6411b1fd4fef5e7e263c5c464b8fcd9d3efdea7ebb0630aff161b79df1d5af46f178968f0b9dc0403
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/metadata@4.14.1, @polkadot/metadata@workspace:packages/metadata":
|
||||
"@polkadot/metadata@4.15.1, @polkadot/metadata@workspace:packages/metadata":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/metadata@workspace:packages/metadata"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/types-known": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/util-crypto": ^6.8.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/types-known": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/util-crypto": ^6.9.1
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/networks@npm:6.8.1, @polkadot/networks@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/networks@npm:6.8.1"
|
||||
"@polkadot/networks@npm:6.9.1, @polkadot/networks@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/networks@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
checksum: aa0f1aaef0a025982e0165449aa2e6534d968ed691374c9397d28659baf85075767412085b592ac6cdb4c36496f142e11f75642a6b12775a0bb98f42916ecdf7
|
||||
checksum: 204fa83cef8433d4f634c98e8d638cf3c309848678b4f769f75d53687af7169b8b6c3e58552bf534daab8b5305c73c9ae036229c708aaa124f4b3e70853ba3fa
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/rpc-core@4.14.1, @polkadot/rpc-core@workspace:packages/rpc-core":
|
||||
"@polkadot/rpc-core@4.15.1, @polkadot/rpc-core@workspace:packages/rpc-core":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/rpc-core@workspace:packages/rpc-core"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/metadata": 4.14.1
|
||||
"@polkadot/rpc-provider": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/x-rxjs": ^6.8.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/metadata": 4.15.1
|
||||
"@polkadot/rpc-provider": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/x-rxjs": ^6.9.1
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/rpc-provider@4.14.1, @polkadot/rpc-provider@workspace:packages/rpc-provider":
|
||||
"@polkadot/rpc-provider@4.15.1, @polkadot/rpc-provider@workspace:packages/rpc-provider":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/rpc-provider@workspace:packages/rpc-provider"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/metadata": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/util-crypto": ^6.8.1
|
||||
"@polkadot/x-fetch": ^6.8.1
|
||||
"@polkadot/x-global": ^6.8.1
|
||||
"@polkadot/x-ws": ^6.8.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/metadata": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/util-crypto": ^6.9.1
|
||||
"@polkadot/x-fetch": ^6.9.1
|
||||
"@polkadot/x-global": ^6.9.1
|
||||
"@polkadot/x-ws": ^6.9.1
|
||||
eventemitter3: ^4.0.7
|
||||
mock-socket: ^9.0.3
|
||||
nock: ^13.1.0
|
||||
@@ -2062,11 +2062,11 @@ __metadata:
|
||||
"@babel/core": ^7.14.5
|
||||
"@babel/register": ^7.14.5
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/api": 4.14.1
|
||||
"@polkadot/metadata": 4.14.1
|
||||
"@polkadot/rpc-provider": 4.14.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/api": 4.15.1
|
||||
"@polkadot/metadata": 4.15.1
|
||||
"@polkadot/rpc-provider": 4.15.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@types/websocket": ^1.0.2
|
||||
"@types/yargs": ^17.0.0
|
||||
handlebars: ^4.7.7
|
||||
@@ -2081,41 +2081,41 @@ __metadata:
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/types-known@4.14.1, @polkadot/types-known@workspace:packages/types-known":
|
||||
"@polkadot/types-known@4.15.1, @polkadot/types-known@workspace:packages/types-known":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/types-known@workspace:packages/types-known"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/networks": ^6.8.1
|
||||
"@polkadot/types": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/networks": ^6.9.1
|
||||
"@polkadot/types": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/types@4.14.1, @polkadot/types@workspace:packages/types":
|
||||
"@polkadot/types@4.15.1, @polkadot/types@workspace:packages/types":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@polkadot/types@workspace:packages/types"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/keyring": ^6.8.1
|
||||
"@polkadot/metadata": 4.14.1
|
||||
"@polkadot/util": ^6.8.1
|
||||
"@polkadot/util-crypto": ^6.8.1
|
||||
"@polkadot/x-rxjs": ^6.8.1
|
||||
"@polkadot/keyring": ^6.9.1
|
||||
"@polkadot/metadata": 4.15.1
|
||||
"@polkadot/util": ^6.9.1
|
||||
"@polkadot/util-crypto": ^6.9.1
|
||||
"@polkadot/x-rxjs": ^6.9.1
|
||||
"@types/bn.js": ^4.11.6
|
||||
bn.js: ^4.11.9
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@polkadot/util-crypto@npm:6.8.1, @polkadot/util-crypto@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/util-crypto@npm:6.8.1"
|
||||
"@polkadot/util-crypto@npm:6.9.1, @polkadot/util-crypto@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/util-crypto@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/networks": 6.8.1
|
||||
"@polkadot/util": 6.8.1
|
||||
"@polkadot/networks": 6.9.1
|
||||
"@polkadot/util": 6.9.1
|
||||
"@polkadot/wasm-crypto": ^4.0.2
|
||||
"@polkadot/x-randomvalues": 6.8.1
|
||||
"@polkadot/x-randomvalues": 6.9.1
|
||||
base-x: ^3.0.8
|
||||
base64-js: ^1.5.1
|
||||
blakejs: ^1.1.0
|
||||
@@ -2128,23 +2128,23 @@ __metadata:
|
||||
tweetnacl: ^1.0.3
|
||||
xxhashjs: ^0.2.2
|
||||
peerDependencies:
|
||||
"@polkadot/util": 6.8.1
|
||||
checksum: c2b2e10afb88654c170e4aa0020a1a636ab2a38a6c63c398fc2f100e848a15802afc3916a43cc441d571657e09d624f2289cf99dd7183909d3d4d6a41d257a5c
|
||||
"@polkadot/util": 6.9.1
|
||||
checksum: 11a3a4d2a223e700096e8f153679dd6865918faa3e9bef54865354d3836ae563b9a078b2fb5733c625a60fe410ce2b2f8306970dfac2f224970c17822e8dadc6
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/util@npm:6.8.1, @polkadot/util@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/util@npm:6.8.1"
|
||||
"@polkadot/util@npm:6.9.1, @polkadot/util@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/util@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-textdecoder": 6.8.1
|
||||
"@polkadot/x-textencoder": 6.8.1
|
||||
"@polkadot/x-textdecoder": 6.9.1
|
||||
"@polkadot/x-textencoder": 6.9.1
|
||||
"@types/bn.js": ^4.11.6
|
||||
bn.js: ^4.11.9
|
||||
camelcase: ^5.3.1
|
||||
ip-regex: ^4.3.0
|
||||
checksum: d460d4df7677b10cbef210795d648fda3c21dbb231c82fa46bf8e91ec1cede17fb39e7606daa00af5c1220ad304fd3a9993369a16948a3725673fdf9b914aeb6
|
||||
checksum: 709482f8bdbb6fe6737c3e1ac0fb9a7c637f5524d8cb8015cedffe3b5b84f46a02ee241db0935993f8117bd7fec3981f03638069007f14f12053fdd7ce4b1a6e
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -2180,78 +2180,78 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-fetch@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-fetch@npm:6.8.1"
|
||||
"@polkadot/x-fetch@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-fetch@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-global": 6.8.1
|
||||
"@polkadot/x-global": 6.9.1
|
||||
"@types/node-fetch": ^2.5.10
|
||||
node-fetch: ^2.6.1
|
||||
checksum: 6f42660719e3db07bb4763e0a6bf0dca2a9fca10a083e506ea822f44e6e28ab170ac1fc908392675722ed8cf942c510cf1659b80704baa59e3030c73f017cb5b
|
||||
checksum: d5522011cfadaea2ab2ce9a3baeda7c3ea2bc189250720f07234134430c4fc9d34420cd33d849cb93ea18a948083e2e069d733897b0cb751ef5d5ca962a3ac5d
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-global@npm:6.8.1, @polkadot/x-global@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-global@npm:6.8.1"
|
||||
"@polkadot/x-global@npm:6.9.1, @polkadot/x-global@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-global@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@types/node-fetch": ^2.5.10
|
||||
node-fetch: ^2.6.1
|
||||
checksum: a7cbfae8896643551fcb1a039667ea009a91548fe1f194c3b158e0bca5ade38b10b4b74b3da5a20ee0ba8752a59806077b455cbe76fb316c345c70e5f39e2d44
|
||||
checksum: ba16d9875592dff8c60478089567988c521cce7ea008916325ead97d3aec683d2ebaf950f31de3be45358f2c54f8aa0f0155a4676321dc9d3d1f986cb06bc84d
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-randomvalues@npm:6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-randomvalues@npm:6.8.1"
|
||||
"@polkadot/x-randomvalues@npm:6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-randomvalues@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-global": 6.8.1
|
||||
checksum: 28f64cc3de95e582ca234f540f5a8a8c49a2af4f45c7ba3a578487517ff2a5b42d75d10bc0c111942ed4d7a3ba07ab600f678a3af340f9cf7dc7247055e757d3
|
||||
"@polkadot/x-global": 6.9.1
|
||||
checksum: fbd36b00c07b1f2656094f4032d4638e83d5591c86c9528ab10705633133746aa85bdbab18d6ebe21ef7bc95a03b57022512542400938ae0bf56e4ca0b650392
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-rxjs@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-rxjs@npm:6.8.1"
|
||||
"@polkadot/x-rxjs@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-rxjs@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
rxjs: ^6.6.7
|
||||
checksum: 61b9c179ed9e6de6878f4ebceea7386e2f79bafb307c0f6a74fddddd57c91bf7ee7571d73c8a9b4af8f7c4d84ed0edb676f243620d285a88dbe467cd3a8a0e77
|
||||
checksum: f76da1b52ea29e34b8625b2ad4b98592e0430e86e48cbccd048b6a8a882e89518341ac4605e3327d8da382b74d184f884df45e0ccf4a3912e021090d1ce9eb2a
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-textdecoder@npm:6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-textdecoder@npm:6.8.1"
|
||||
"@polkadot/x-textdecoder@npm:6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-textdecoder@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-global": 6.8.1
|
||||
checksum: d9ea7ff97cf7c67044fc7306c756574938ec1fa3a958fecf7c95fdbb280f64737fd4d84258e9c917433b8b790e91b77270491b4c4ed0bd4899937ed0a92afdb8
|
||||
"@polkadot/x-global": 6.9.1
|
||||
checksum: 16e42e15448025fbcd4b4419f14c7fddd29cd179dd61c26a9b76cb3378c307694bcca171c616aed7c4c89d5807e45c02fbf0435380e9197a525469ec2389c76a
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-textencoder@npm:6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-textencoder@npm:6.8.1"
|
||||
"@polkadot/x-textencoder@npm:6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-textencoder@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-global": 6.8.1
|
||||
checksum: 706e69130f0deac0dd3e4d8c09acf66b9a55b932bbc062f15a48db99e90c636216a9fce1233198abd20fad94a05f3943867bf924d4d0227f8a9ef40a2136bc61
|
||||
"@polkadot/x-global": 6.9.1
|
||||
checksum: 7c0ea24cc49c103b782d169ad6647a179834a6539aaa835ca040926db071f64e703d0ce830a17a84ed1ddd5631340525192ad272c95a5137d7e8eb056abccc04
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/x-ws@npm:^6.8.1":
|
||||
version: 6.8.1
|
||||
resolution: "@polkadot/x-ws@npm:6.8.1"
|
||||
"@polkadot/x-ws@npm:^6.9.1":
|
||||
version: 6.9.1
|
||||
resolution: "@polkadot/x-ws@npm:6.9.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.14.5
|
||||
"@polkadot/x-global": 6.8.1
|
||||
"@polkadot/x-global": 6.9.1
|
||||
"@types/websocket": ^1.0.2
|
||||
websocket: ^1.0.34
|
||||
checksum: 424935cf3b11f9fda1534942e958e55ad5e5f625c8ebd4e7a00b176d56c10413549394215dce5654ffba3560b5ff3c350ebc32ac8b9b7249e604cdc1a3f842bc
|
||||
checksum: 0101b449615eac3eb8f2997f03e50cc8076c9fc118804bb49f6f3169e430542f79766ba33598c5d6076c5a4cb3fc55094058bcd48408b8a7552511e10592b799
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
|
||||
Reference in New Issue
Block a user