Adjust to new auction types (#3297)

* Adjust to new auction types

* Update BitVec fields, Babe types
This commit is contained in:
Jaco Greeff
2021-03-10 22:00:57 +01:00
committed by GitHub
parent 5bec38c404
commit fa0add8564
11 changed files with 102 additions and 133 deletions
+14 -29
View File
@@ -7,7 +7,7 @@ import type { BlockAttestations, IncludedBlocks, MoreAttestations } from '@polka
import type { RawAuraPreDigest } from '@polkadot/types/interfaces/aura';
import type { ExtrinsicOrHash, ExtrinsicStatus } from '@polkadot/types/interfaces/author';
import type { UncleEntryItem } from '@polkadot/types/interfaces/authorship';
import type { AllowedSlots, BabeAuthorityWeight, BabeBlockWeight, 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 { 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, VestingSchedule, WithdrawReasons } from '@polkadot/types/interfaces/balances';
import type { BlockHash } from '@polkadot/types/interfaces/chain';
import type { PrefixedStorageKey } from '@polkadot/types/interfaces/childstate';
@@ -16,7 +16,7 @@ import type { CollectiveOrigin, MemberCount, ProposalIndex, Votes, VotesTo230 }
import type { AuthorityId, RawVRFOutput } from '@polkadot/types/interfaces/consensus';
import type { AliveContractInfo, CodeHash, ContractCallRequest, ContractExecResult, ContractExecResultErr, ContractExecResultErrModule, ContractExecResultOk, ContractExecResultResult, ContractExecResultSuccessTo255, ContractExecResultSuccessTo260, ContractExecResultTo255, ContractExecResultTo260, ContractInfo, ContractStorageKey, DeletedContract, Gas, HostFnWeights, HostFnWeightsTo264, InstructionWeights, Limits, LimitsTo264, PrefabWasmModule, PrefabWasmModuleReserved, Schedule, ScheduleTo212, ScheduleTo258, ScheduleTo264, SeedOf, TombstoneContractInfo, TrieId } from '@polkadot/types/interfaces/contracts';
import type { ContractConstructorSpec, ContractContractSpec, ContractCryptoHasher, ContractDiscriminant, ContractDisplayName, ContractEventParamSpec, ContractEventSpec, ContractLayoutArray, ContractLayoutCell, ContractLayoutEnum, ContractLayoutHash, ContractLayoutHashingStrategy, ContractLayoutKey, ContractLayoutStruct, ContractLayoutStructField, ContractMessageParamSpec, ContractMessageSpec, ContractProject, ContractProjectContract, ContractProjectSource, ContractSelector, ContractStorageLayout, ContractTypeSpec } from '@polkadot/types/interfaces/contractsAbi';
import type { DeployData, FundIndex, FundInfo, LastContribution } from '@polkadot/types/interfaces/crowdloan';
import type { FundIndex, FundInfo, LastContribution, TrieIndex } from '@polkadot/types/interfaces/crowdloan';
import type { AccountVote, AccountVoteSplit, AccountVoteStandard, Conviction, Delegations, PreimageStatus, PreimageStatusAvailable, PriorLock, PropIndex, Proposal, ProxyState, ReferendumIndex, ReferendumInfo, ReferendumInfoFinished, ReferendumInfoTo239, ReferendumStatus, Tally, Voting, VotingDelegating, VotingDirect, VotingDirectVote } from '@polkadot/types/interfaces/democracy';
import type { ApprovalFlag, DefunctVoter, Renouncing, SetIndex, Vote, VoteIndex, VoteThreshold, VoterInfo } from '@polkadot/types/interfaces/elections';
import type { CreatedBlock, ImportedAux } from '@polkadot/types/interfaces/engine';
@@ -32,14 +32,14 @@ import type { CallIndex, LotteryConfig } from '@polkadot/types/interfaces/lotter
import type { DoubleMapTypeLatest, DoubleMapTypeV10, DoubleMapTypeV11, DoubleMapTypeV12, DoubleMapTypeV9, ErrorMetadataLatest, ErrorMetadataV10, ErrorMetadataV11, ErrorMetadataV12, ErrorMetadataV9, EventMetadataLatest, EventMetadataV10, EventMetadataV11, EventMetadataV12, EventMetadataV9, ExtrinsicMetadataLatest, ExtrinsicMetadataV11, ExtrinsicMetadataV12, FunctionArgumentMetadataLatest, FunctionArgumentMetadataV10, FunctionArgumentMetadataV11, FunctionArgumentMetadataV12, FunctionArgumentMetadataV9, FunctionMetadataLatest, FunctionMetadataV10, FunctionMetadataV11, FunctionMetadataV12, FunctionMetadataV9, MapTypeLatest, MapTypeV10, MapTypeV11, MapTypeV12, MapTypeV9, MetadataAll, MetadataLatest, MetadataV10, MetadataV11, MetadataV12, MetadataV9, ModuleConstantMetadataLatest, ModuleConstantMetadataV10, ModuleConstantMetadataV11, ModuleConstantMetadataV12, ModuleConstantMetadataV9, ModuleMetadataLatest, ModuleMetadataV10, ModuleMetadataV11, ModuleMetadataV12, ModuleMetadataV9, StorageEntryMetadataLatest, StorageEntryMetadataV10, StorageEntryMetadataV11, StorageEntryMetadataV12, StorageEntryMetadataV9, StorageEntryModifierLatest, StorageEntryModifierV10, StorageEntryModifierV11, StorageEntryModifierV12, StorageEntryModifierV9, StorageEntryTypeLatest, StorageEntryTypeV10, StorageEntryTypeV11, StorageEntryTypeV12, StorageEntryTypeV9, StorageHasher, StorageHasherV10, StorageHasherV11, StorageHasherV12, StorageHasherV9, StorageMetadataLatest, StorageMetadataV10, StorageMetadataV11, StorageMetadataV12, StorageMetadataV9 } from '@polkadot/types/interfaces/metadata';
import type { StorageKind } from '@polkadot/types/interfaces/offchain';
import type { DeferredOffenceOf, Kind, OffenceDetails, Offender, OpaqueTimeSlot, ReportIdOf, Reporter } from '@polkadot/types/interfaces/offences';
import type { AbridgedCandidateReceipt, AbridgedHostConfiguration, AbridgedHrmpChannel, AbstractFungible, AbstractNonFungible, AccountId32Junction, AccountIndex64Junction, AccountKey20Junction, AssetInstance, AssignmentId, AssignmentKind, AttestedCandidate, AuctionIndex, AuthorityDiscoveryId, AvailabilityBitfield, AvailabilityBitfieldRecord, BackedCandidate, Balances, Bidder, BufferedSessionChange, CandidateCommitments, CandidateDescriptor, CandidateHash, CandidatePendingAvailability, CandidateReceipt, CollatorId, CollatorSignature, CommittedCandidateReceipt, ConcreteFungible, ConcreteNonFungible, CoreAssignment, CoreIndex, CoreOccupied, DepositAsset, DepositReserveAsset, DoubleVoteReport, DownwardMessage, ExchangeAsset, GlobalValidationSchedule, GroupIndex, HeadData, HostConfiguration, HrmpChannel, HrmpChannelId, HrmpOpenChannelRequest, InboundDownwardMessage, InboundHrmpMessage, InboundHrmpMessages, IncomingParachain, IncomingParachainDeploy, IncomingParachainFixed, InitiateReserveWithdraw, InitiateTeleport, Junction, LeasePeriod, LeasePeriodOf, LocalValidationData, MessageIngestionType, MessageQueueChain, MessagingStateSnapshot, MessagingStateSnapshotEgressEntry, MultiAsset, MultiLocation, NetworkId, NewBidder, NewBidderOption, Order, OriginKind, OutboundHrmpMessage, ParaGenesisArgs, ParaId, ParaInfo, ParaLifecycle, ParaPastCodeMeta, ParaScheduling, ParaValidatorIndex, ParachainDispatchOrigin, ParachainInherentData, ParachainProposal, ParathreadClaim, ParathreadClaimQueue, ParathreadEntry, PersistedValidationData, QueryHolding, QueuedParathread, RegisteredParachainInfo, RelayChainBlockNumber, RelayChainHash, RelayTo, RelayedFrom, Remark, ReserveAssetDeposit, Retriable, Scheduling, SessionInfo, SessionInfoValidatorGroup, SignedAvailabilityBitfield, SignedAvailabilityBitfields, SigningContext, SlotRange, Statement, SubId, SystemInherentData, TeleportAsset, Transact, TransientValidationData, UpwardMessage, ValidationCode, ValidationData, ValidationDataType, ValidationFunctionParams, ValidatorSignature, ValidityAttestation, VecInboundHrmpMessage, VersionedMultiAsset, VersionedMultiLocation, VersionedXcm, WinnersData, WinnersDataTuple, WinningData, WinningDataEntry, WithdrawAsset, Xcm, XcmError, XcmResult } from '@polkadot/types/interfaces/parachains';
import type { AbridgedCandidateReceipt, AbridgedHostConfiguration, AbridgedHrmpChannel, AbstractFungible, AbstractNonFungible, AccountId32Junction, AccountIndex64Junction, AccountKey20Junction, AssetInstance, AssignmentId, AssignmentKind, AttestedCandidate, AuctionIndex, AuthorityDiscoveryId, AvailabilityBitfield, AvailabilityBitfieldRecord, BackedCandidate, Balances, BufferedSessionChange, CandidateCommitments, CandidateDescriptor, CandidateHash, CandidatePendingAvailability, CandidateReceipt, CollatorId, CollatorSignature, CommittedCandidateReceipt, ConcreteFungible, ConcreteNonFungible, CoreAssignment, CoreIndex, CoreOccupied, DepositAsset, DepositReserveAsset, DoubleVoteReport, DownwardMessage, ExchangeAsset, GlobalValidationSchedule, GroupIndex, HeadData, HostConfiguration, HrmpChannel, HrmpChannelId, HrmpOpenChannelRequest, InboundDownwardMessage, InboundHrmpMessage, InboundHrmpMessages, InitiateReserveWithdraw, InitiateTeleport, Junction, LeasePeriod, LeasePeriodOf, LocalValidationData, MessageIngestionType, MessageQueueChain, MessagingStateSnapshot, MessagingStateSnapshotEgressEntry, MultiAsset, MultiLocation, NetworkId, Order, OriginKind, OutboundHrmpMessage, ParaGenesisArgs, ParaId, ParaInfo, ParaLifecycle, ParaPastCodeMeta, ParaScheduling, ParaValidatorIndex, ParachainDispatchOrigin, ParachainInherentData, ParachainProposal, ParathreadClaim, ParathreadClaimQueue, ParathreadEntry, PersistedValidationData, QueryHolding, QueuedParathread, RegisteredParachainInfo, RelayChainBlockNumber, RelayChainHash, RelayTo, RelayedFrom, Remark, ReserveAssetDeposit, Retriable, Scheduling, SessionInfo, SessionInfoValidatorGroup, SignedAvailabilityBitfield, SignedAvailabilityBitfields, SigningContext, SlotRange, Statement, SystemInherentData, TeleportAsset, Transact, TransientValidationData, UpwardMessage, ValidationCode, ValidationData, ValidationDataType, ValidationFunctionParams, ValidatorSignature, ValidityAttestation, VecInboundHrmpMessage, VersionedMultiAsset, VersionedMultiLocation, VersionedXcm, WinnersData, WinnersDataTuple, WinningData, WinningDataEntry, WithdrawAsset, Xcm, XcmError, XcmResult } from '@polkadot/types/interfaces/parachains';
import type { FeeDetails, InclusionFee, RuntimeDispatchInfo } from '@polkadot/types/interfaces/payment';
import type { Approvals } from '@polkadot/types/interfaces/poll';
import type { ProxyAnnouncement, ProxyDefinition, ProxyType } from '@polkadot/types/interfaces/proxy';
import type { AccountStatus, AccountValidity } from '@polkadot/types/interfaces/purchase';
import type { ActiveRecovery, RecoveryConfig } from '@polkadot/types/interfaces/recovery';
import type { RpcMethods } from '@polkadot/types/interfaces/rpc';
import type { AccountId, AccountIdOf, AccountIndex, Address, AssetId, Balance, BalanceOf, Block, BlockNumber, Call, CallHash, CallHashOf, ChangesTrieConfiguration, CodecHash, Consensus, ConsensusEngineId, Digest, DigestItem, ExtrinsicsWeight, Fixed128, Fixed64, FixedI128, FixedI64, FixedU128, FixedU64, H1024, H128, H160, H2048, H256, H512, H64, Hash, Header, I32F32, Index, IndicesLookupSource, Justification, KeyTypeId, KeyValue, LockIdentifier, LookupSource, LookupTarget, ModuleId, Moment, MultiAddress, OpaqueCall, Origin, OriginCaller, PalletVersion, PalletsOrigin, Pays, PerU16, Perbill, Percent, Permill, Perquintill, Phantom, PhantomData, PreRuntime, Releases, RuntimeDbWeight, Seal, SealV0, SignedBlock, Slot, StorageData, StorageProof, TransactionPriority, U32F32, ValidatorId, ValidatorIdOf, Weight, WeightMultiplier } from '@polkadot/types/interfaces/runtime';
import type { AccountId, AccountIdOf, AccountIndex, Address, AssetId, Balance, BalanceOf, Block, BlockNumber, Call, CallHash, CallHashOf, ChangesTrieConfiguration, CodecHash, Consensus, ConsensusEngineId, Digest, DigestItem, ExtrinsicsWeight, Fixed128, Fixed64, FixedI128, FixedI64, FixedU128, FixedU64, H1024, H128, H160, H2048, H256, H512, H64, Hash, Header, I32F32, Index, IndicesLookupSource, Justification, KeyTypeId, KeyValue, LockIdentifier, LookupSource, LookupTarget, ModuleId, Moment, MultiAddress, MultiSigner, OpaqueCall, Origin, OriginCaller, PalletVersion, PalletsOrigin, Pays, PerU16, Perbill, Percent, Permill, Perquintill, Phantom, PhantomData, PreRuntime, Releases, RuntimeDbWeight, Seal, SealV0, SignedBlock, Slot, StorageData, StorageProof, TransactionPriority, U32F32, ValidatorId, ValidatorIdOf, Weight, WeightMultiplier } from '@polkadot/types/interfaces/runtime';
import type { SiField, SiLookupTypeId, SiPath, SiType, SiTypeDef, SiTypeDefArray, SiTypeDefComposite, SiTypeDefPrimitive, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiVariant } from '@polkadot/types/interfaces/scaleInfo';
import type { Period, Priority, SchedulePeriod, SchedulePriority, Scheduled, ScheduledTo254, TaskAddress } from '@polkadot/types/interfaces/scheduler';
import type { FullIdentification, IdentificationTuple, Keys, MembershipProof, SessionIndex, SessionKeys1, SessionKeys2, SessionKeys3, SessionKeys4, SessionKeys5, SessionKeys6, SessionKeys7, SessionKeys8, SessionKeys9, ValidatorCount } from '@polkadot/types/interfaces/session';
@@ -116,10 +116,10 @@ declare module '@polkadot/types/types/registry' {
'Compact<SlotNumber>': Compact<SlotNumber>;
'Compact<SpanIndex>': Compact<SpanIndex>;
'Compact<StrikeCount>': Compact<StrikeCount>;
'Compact<SubId>': Compact<SubId>;
'Compact<TAssetBalance>': Compact<TAssetBalance>;
'Compact<TAssetDepositBalance>': Compact<TAssetDepositBalance>;
'Compact<TransactionPriority>': Compact<TransactionPriority>;
'Compact<TrieIndex>': Compact<TrieIndex>;
'Compact<u128>': Compact<u128>;
'Compact<U128>': Compact<U128>;
'Compact<u16>': Compact<u16>;
@@ -196,6 +196,7 @@ declare module '@polkadot/types/types/registry' {
'Option<AvailabilityBitfieldRecord>': Option<AvailabilityBitfieldRecord>;
'Option<BabeAuthorityWeight>': Option<BabeAuthorityWeight>;
'Option<BabeBlockWeight>': Option<BabeBlockWeight>;
'Option<BabeEpochConfiguration>': Option<BabeEpochConfiguration>;
'Option<BabeEquivocationProof>': Option<BabeEquivocationProof>;
'Option<BabeWeight>': Option<BabeWeight>;
'Option<BackedCandidate>': Option<BackedCandidate>;
@@ -206,7 +207,6 @@ declare module '@polkadot/types/types/registry' {
'Option<Balances>': Option<Balances>;
'Option<BalanceStatus>': Option<BalanceStatus>;
'Option<Bid>': Option<Bid>;
'Option<Bidder>': Option<Bidder>;
'Option<BidKind>': Option<BidKind>;
'Option<BitVec>': Option<BitVec>;
'Option<Block>': Option<Block>;
@@ -297,7 +297,6 @@ declare module '@polkadot/types/types/registry' {
'Option<DefunctVoter>': Option<DefunctVoter>;
'Option<Delegations>': Option<Delegations>;
'Option<DeletedContract>': Option<DeletedContract>;
'Option<DeployData>': Option<DeployData>;
'Option<DepositAsset>': Option<DepositAsset>;
'Option<DepositReserveAsset>': Option<DepositReserveAsset>;
'Option<Digest>': Option<Digest>;
@@ -480,9 +479,6 @@ declare module '@polkadot/types/types/registry' {
'Option<InboundHrmpMessages>': Option<InboundHrmpMessages>;
'Option<IncludedBlocks>': Option<IncludedBlocks>;
'Option<InclusionFee>': Option<InclusionFee>;
'Option<IncomingParachain>': Option<IncomingParachain>;
'Option<IncomingParachainDeploy>': Option<IncomingParachainDeploy>;
'Option<IncomingParachainFixed>': Option<IncomingParachainFixed>;
'Option<Index>': Option<Index>;
'Option<IndicesLookupSource>': Option<IndicesLookupSource>;
'Option<IndividualExposure>': Option<IndividualExposure>;
@@ -553,12 +549,11 @@ declare module '@polkadot/types/types/registry' {
'Option<Multiplier>': Option<Multiplier>;
'Option<Multisig>': Option<Multisig>;
'Option<MultiSignature>': Option<MultiSignature>;
'Option<MultiSigner>': Option<MultiSigner>;
'Option<NetworkId>': Option<NetworkId>;
'Option<NetworkState>': Option<NetworkState>;
'Option<NetworkStatePeerset>': Option<NetworkStatePeerset>;
'Option<NetworkStatePeersetInfo>': Option<NetworkStatePeersetInfo>;
'Option<NewBidder>': Option<NewBidder>;
'Option<NewBidderOption>': Option<NewBidderOption>;
'Option<NextAuthority>': Option<NextAuthority>;
'Option<NextConfigDescriptor>': Option<NextConfigDescriptor>;
'Option<NextConfigDescriptorV1>': Option<NextConfigDescriptorV1>;
@@ -795,7 +790,6 @@ declare module '@polkadot/types/types/registry' {
'Option<StoredPendingChange>': Option<StoredPendingChange>;
'Option<StoredState>': Option<StoredState>;
'Option<StrikeCount>': Option<StrikeCount>;
'Option<SubId>': Option<SubId>;
'Option<SyncState>': Option<SyncState>;
'Option<SystemInherentData>': Option<SystemInherentData>;
'Option<SystemOrigin>': Option<SystemOrigin>;
@@ -813,6 +807,7 @@ declare module '@polkadot/types/types/registry' {
'Option<TransientValidationData>': Option<TransientValidationData>;
'Option<TreasuryProposal>': Option<TreasuryProposal>;
'Option<TrieId>': Option<TrieId>;
'Option<TrieIndex>': Option<TrieIndex>;
'Option<Type>': Option<Type>;
'Option<u128>': Option<u128>;
'Option<U128>': Option<U128>;
@@ -942,6 +937,7 @@ declare module '@polkadot/types/types/registry' {
'Vec<AvailabilityBitfieldRecord>': Vec<AvailabilityBitfieldRecord>;
'Vec<BabeAuthorityWeight>': Vec<BabeAuthorityWeight>;
'Vec<BabeBlockWeight>': Vec<BabeBlockWeight>;
'Vec<BabeEpochConfiguration>': Vec<BabeEpochConfiguration>;
'Vec<BabeEquivocationProof>': Vec<BabeEquivocationProof>;
'Vec<BabeWeight>': Vec<BabeWeight>;
'Vec<BackedCandidate>': Vec<BackedCandidate>;
@@ -952,7 +948,6 @@ declare module '@polkadot/types/types/registry' {
'Vec<Balances>': Vec<Balances>;
'Vec<BalanceStatus>': Vec<BalanceStatus>;
'Vec<Bid>': Vec<Bid>;
'Vec<Bidder>': Vec<Bidder>;
'Vec<BidKind>': Vec<BidKind>;
'Vec<BitVec>': Vec<BitVec>;
'Vec<Block>': Vec<Block>;
@@ -1043,7 +1038,6 @@ declare module '@polkadot/types/types/registry' {
'Vec<DefunctVoter>': Vec<DefunctVoter>;
'Vec<Delegations>': Vec<Delegations>;
'Vec<DeletedContract>': Vec<DeletedContract>;
'Vec<DeployData>': Vec<DeployData>;
'Vec<DepositAsset>': Vec<DepositAsset>;
'Vec<DepositReserveAsset>': Vec<DepositReserveAsset>;
'Vec<Digest>': Vec<Digest>;
@@ -1226,9 +1220,6 @@ declare module '@polkadot/types/types/registry' {
'Vec<InboundHrmpMessages>': Vec<InboundHrmpMessages>;
'Vec<IncludedBlocks>': Vec<IncludedBlocks>;
'Vec<InclusionFee>': Vec<InclusionFee>;
'Vec<IncomingParachain>': Vec<IncomingParachain>;
'Vec<IncomingParachainDeploy>': Vec<IncomingParachainDeploy>;
'Vec<IncomingParachainFixed>': Vec<IncomingParachainFixed>;
'Vec<Index>': Vec<Index>;
'Vec<IndicesLookupSource>': Vec<IndicesLookupSource>;
'Vec<IndividualExposure>': Vec<IndividualExposure>;
@@ -1299,12 +1290,11 @@ declare module '@polkadot/types/types/registry' {
'Vec<Multiplier>': Vec<Multiplier>;
'Vec<Multisig>': Vec<Multisig>;
'Vec<MultiSignature>': Vec<MultiSignature>;
'Vec<MultiSigner>': Vec<MultiSigner>;
'Vec<NetworkId>': Vec<NetworkId>;
'Vec<NetworkState>': Vec<NetworkState>;
'Vec<NetworkStatePeerset>': Vec<NetworkStatePeerset>;
'Vec<NetworkStatePeersetInfo>': Vec<NetworkStatePeersetInfo>;
'Vec<NewBidder>': Vec<NewBidder>;
'Vec<NewBidderOption>': Vec<NewBidderOption>;
'Vec<NextAuthority>': Vec<NextAuthority>;
'Vec<NextConfigDescriptor>': Vec<NextConfigDescriptor>;
'Vec<NextConfigDescriptorV1>': Vec<NextConfigDescriptorV1>;
@@ -1541,7 +1531,6 @@ declare module '@polkadot/types/types/registry' {
'Vec<StoredPendingChange>': Vec<StoredPendingChange>;
'Vec<StoredState>': Vec<StoredState>;
'Vec<StrikeCount>': Vec<StrikeCount>;
'Vec<SubId>': Vec<SubId>;
'Vec<SyncState>': Vec<SyncState>;
'Vec<SystemInherentData>': Vec<SystemInherentData>;
'Vec<SystemOrigin>': Vec<SystemOrigin>;
@@ -1559,6 +1548,7 @@ declare module '@polkadot/types/types/registry' {
'Vec<TransientValidationData>': Vec<TransientValidationData>;
'Vec<TreasuryProposal>': Vec<TreasuryProposal>;
'Vec<TrieId>': Vec<TrieId>;
'Vec<TrieIndex>': Vec<TrieIndex>;
'Vec<Type>': Vec<Type>;
'Vec<u128>': Vec<u128>;
'Vec<U128>': Vec<U128>;
@@ -1688,6 +1678,7 @@ declare module '@polkadot/types/types/registry' {
AvailabilityBitfieldRecord: AvailabilityBitfieldRecord;
BabeAuthorityWeight: BabeAuthorityWeight;
BabeBlockWeight: BabeBlockWeight;
BabeEpochConfiguration: BabeEpochConfiguration;
BabeEquivocationProof: BabeEquivocationProof;
BabeWeight: BabeWeight;
BackedCandidate: BackedCandidate;
@@ -1698,7 +1689,6 @@ declare module '@polkadot/types/types/registry' {
Balances: Balances;
BalanceStatus: BalanceStatus;
Bid: Bid;
Bidder: Bidder;
BidKind: BidKind;
BitVec: BitVec;
Block: Block;
@@ -1789,7 +1779,6 @@ declare module '@polkadot/types/types/registry' {
DefunctVoter: DefunctVoter;
Delegations: Delegations;
DeletedContract: DeletedContract;
DeployData: DeployData;
DepositAsset: DepositAsset;
DepositReserveAsset: DepositReserveAsset;
Digest: Digest;
@@ -1972,9 +1961,6 @@ declare module '@polkadot/types/types/registry' {
InboundHrmpMessages: InboundHrmpMessages;
IncludedBlocks: IncludedBlocks;
InclusionFee: InclusionFee;
IncomingParachain: IncomingParachain;
IncomingParachainDeploy: IncomingParachainDeploy;
IncomingParachainFixed: IncomingParachainFixed;
Index: Index;
IndicesLookupSource: IndicesLookupSource;
IndividualExposure: IndividualExposure;
@@ -2045,12 +2031,11 @@ declare module '@polkadot/types/types/registry' {
Multiplier: Multiplier;
Multisig: Multisig;
MultiSignature: MultiSignature;
MultiSigner: MultiSigner;
NetworkId: NetworkId;
NetworkState: NetworkState;
NetworkStatePeerset: NetworkStatePeerset;
NetworkStatePeersetInfo: NetworkStatePeersetInfo;
NewBidder: NewBidder;
NewBidderOption: NewBidderOption;
NextAuthority: NextAuthority;
NextConfigDescriptor: NextConfigDescriptor;
NextConfigDescriptorV1: NextConfigDescriptorV1;
@@ -2287,7 +2272,6 @@ declare module '@polkadot/types/types/registry' {
StoredPendingChange: StoredPendingChange;
StoredState: StoredState;
StrikeCount: StrikeCount;
SubId: SubId;
SyncState: SyncState;
SystemInherentData: SystemInherentData;
SystemOrigin: SystemOrigin;
@@ -2305,6 +2289,7 @@ declare module '@polkadot/types/types/registry' {
TransientValidationData: TransientValidationData;
TreasuryProposal: TreasuryProposal;
TrieId: TrieId;
TrieIndex: TrieIndex;
Type: Type;
u128: u128;
U128: U128;
@@ -19,6 +19,10 @@ export default {
_enum: ['PrimarySlots', 'PrimaryAndSecondaryPlainSlots', 'PrimaryAndSecondaryVRFSlots']
},
BabeAuthorityWeight: 'u64',
BabeEpochConfiguration: {
c: '(u64, u64)',
allowedSlots: 'AllowedSlots'
},
BabeBlockWeight: 'u32',
BabeEquivocationProof: {
offender: 'AuthorityId',
@@ -19,6 +19,12 @@ export interface BabeAuthorityWeight extends u64 {}
/** @name BabeBlockWeight */
export interface BabeBlockWeight extends u32 {}
/** @name BabeEpochConfiguration */
export interface BabeEpochConfiguration extends Struct {
readonly c: ITuple<[u64, u64]>;
readonly allowedSlots: AllowedSlots;
}
/** @name BabeEquivocationProof */
export interface BabeEquivocationProof extends Struct {
readonly offender: AuthorityId;
@@ -13,26 +13,23 @@ export default {
LastContribution: {
_enum: {
Never: 'Null',
PreEnding: 'AuctionIndex',
PreEnding: 'u32',
Ending: 'BlockNumber'
}
},
DeployData: {
codeHash: 'Hash',
codeSize: 'u32',
initialHeadData: 'HeadData'
},
FundInfo: {
parachain: 'Option<ParaId>',
owner: 'AccountId',
retiring: 'bool',
depositor: 'AccountId',
verifier: 'Option<MultiSigner>',
deposit: 'Balance',
raised: 'Balance',
end: 'BlockNumber',
cap: 'Balance',
lastContribution: 'LastContribution',
firstSlot: 'BlockNumber',
lastSlot: 'BlockNumber',
deployData: 'Option<DeployData>'
}
firstSlot: 'LeasePeriod',
lastSlot: 'LeasePeriod',
trieIndex: 'TrieIndex'
},
TrieIndex: 'u32'
}
} as Definitions;
@@ -1,41 +1,38 @@
// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
/* eslint-disable */
import type { Enum, Option, Struct, u32 } from '@polkadot/types';
import type { AuctionIndex, HeadData, ParaId } from '@polkadot/types/interfaces/parachains';
import type { AccountId, Balance, BlockNumber, Hash } from '@polkadot/types/interfaces/runtime';
/** @name DeployData */
export interface DeployData extends Struct {
readonly codeHash: Hash;
readonly codeSize: u32;
readonly initialHeadData: HeadData;
}
import type { Enum, Option, Struct, bool, u32 } from '@polkadot/types';
import type { LeasePeriod } from '@polkadot/types/interfaces/parachains';
import type { AccountId, Balance, BlockNumber, MultiSigner } from '@polkadot/types/interfaces/runtime';
/** @name FundIndex */
export interface FundIndex extends u32 {}
/** @name FundInfo */
export interface FundInfo extends Struct {
readonly parachain: Option<ParaId>;
readonly owner: AccountId;
readonly retiring: bool;
readonly depositor: AccountId;
readonly verifier: Option<MultiSigner>;
readonly deposit: Balance;
readonly raised: Balance;
readonly end: BlockNumber;
readonly cap: Balance;
readonly lastContribution: LastContribution;
readonly firstSlot: BlockNumber;
readonly lastSlot: BlockNumber;
readonly deployData: Option<DeployData>;
readonly firstSlot: LeasePeriod;
readonly lastSlot: LeasePeriod;
readonly trieIndex: TrieIndex;
}
/** @name LastContribution */
export interface LastContribution extends Enum {
readonly isNever: boolean;
readonly isPreEnding: boolean;
readonly asPreEnding: AuctionIndex;
readonly asPreEnding: u32;
readonly isEnding: boolean;
readonly asEnding: BlockNumber;
}
/** @name TrieIndex */
export interface TrieIndex extends u32 {}
export type PHANTOM_CROWDLOAN = 'crowdloan';
@@ -8,41 +8,41 @@ const SLOT_RANGE_COUNT = 10;
export default {
AuctionIndex: 'u32',
Bidder: {
_enum: {
New: 'NewBidder',
Existing: 'ParaId'
}
},
IncomingParachain: {
_enum: {
Unset: 'NewBidder',
Fixed: 'IncomingParachainFixed',
Deploy: 'IncomingParachainDeploy'
}
},
IncomingParachainDeploy: {
code: 'ValidationCode',
initialHeadData: 'HeadData'
},
IncomingParachainFixed: {
codeHash: 'Hash',
codeSize: 'u32',
initialHeadData: 'HeadData'
},
// Bidder: {
// _enum: {
// New: 'NewBidder',
// Existing: 'ParaId'
// }
// },
// IncomingParachain: {
// _enum: {
// Unset: 'NewBidder',
// Fixed: 'IncomingParachainFixed',
// Deploy: 'IncomingParachainDeploy'
// }
// },
// IncomingParachainDeploy: {
// code: 'ValidationCode',
// initialHeadData: 'HeadData'
// },
// IncomingParachainFixed: {
// codeHash: 'Hash',
// codeSize: 'u32',
// initialHeadData: 'HeadData'
// },
LeasePeriod: 'BlockNumber',
LeasePeriodOf: 'BlockNumber',
NewBidder: {
who: 'AccountId',
sub: 'SubId'
},
NewBidderOption: 'Option<NewBidder>',
// NewBidder: {
// who: 'AccountId',
// sub: 'SubId'
// },
// NewBidderOption: 'Option<NewBidder>',
SlotRange: {
_enum: ['ZeroZero', 'ZeroOne', 'ZeroTwo', 'ZeroThree', 'OneOne', 'OneTwo', 'OneThree', 'TwoTwo', 'TwoThree', 'ThreeThree']
},
SubId: 'u32',
// SubId: 'u32',
WinningData: `[WinningDataEntry; ${SLOT_RANGE_COUNT}]`,
WinningDataEntry: 'Option<Bidder>',
WinningDataEntry: 'Option<(AccountId, ParaId, BalanceOf)>',
WinnersData: 'Vec<WinnersDataTuple>',
WinnersDataTuple: '(NewBidderOption, ParaId, BalanceOf, SlotRange)'
WinnersDataTuple: '(AccountId, ParaId, BalanceOf, SlotRange)'
};
@@ -141,14 +141,6 @@ export interface Balances extends Struct {
readonly assets: Vec<MultiAsset>;
}
/** @name Bidder */
export interface Bidder extends Enum {
readonly isNew: boolean;
readonly asNew: NewBidder;
readonly isExisting: boolean;
readonly asExisting: ParaId;
}
/** @name BufferedSessionChange */
export interface BufferedSessionChange extends Struct {
readonly applyAt: BlockNumber;
@@ -368,29 +360,6 @@ export interface InboundHrmpMessage extends Struct {
/** @name InboundHrmpMessages */
export interface InboundHrmpMessages extends Vec<InboundHrmpMessage> {}
/** @name IncomingParachain */
export interface IncomingParachain extends Enum {
readonly isUnset: boolean;
readonly asUnset: NewBidder;
readonly isFixed: boolean;
readonly asFixed: IncomingParachainFixed;
readonly isDeploy: boolean;
readonly asDeploy: IncomingParachainDeploy;
}
/** @name IncomingParachainDeploy */
export interface IncomingParachainDeploy extends Struct {
readonly code: ValidationCode;
readonly initialHeadData: HeadData;
}
/** @name IncomingParachainFixed */
export interface IncomingParachainFixed extends Struct {
readonly codeHash: Hash;
readonly codeSize: u32;
readonly initialHeadData: HeadData;
}
/** @name InitiateReserveWithdraw */
export interface InitiateReserveWithdraw extends Struct {
readonly assets: Vec<MultiAsset>;
@@ -502,15 +471,6 @@ export interface NetworkId extends Enum {
readonly isKusama: boolean;
}
/** @name NewBidder */
export interface NewBidder extends Struct {
readonly who: AccountId;
readonly sub: SubId;
}
/** @name NewBidderOption */
export interface NewBidderOption extends Option<NewBidder> {}
/** @name Order */
export interface Order extends Enum {
readonly isNull: boolean;
@@ -746,9 +706,6 @@ export interface Statement extends Enum {
readonly asInvalid: Hash;
}
/** @name SubId */
export interface SubId extends u32 {}
/** @name SystemInherentData */
export interface SystemInherentData extends ParachainInherentData {}
@@ -835,13 +792,13 @@ export interface VersionedXcm extends Enum {
export interface WinnersData extends Vec<WinnersDataTuple> {}
/** @name WinnersDataTuple */
export interface WinnersDataTuple extends ITuple<[NewBidderOption, ParaId, BalanceOf, SlotRange]> {}
export interface WinnersDataTuple extends ITuple<[AccountId, ParaId, BalanceOf, SlotRange]> {}
/** @name WinningData */
export interface WinningData extends Vec<WinningDataEntry> {}
/** @name WinningDataEntry */
export interface WinningDataEntry extends Option<Bidder> {}
export interface WinningDataEntry extends Option<ITuple<[AccountId, ParaId, BalanceOf]>> {}
/** @name WithdrawAsset */
export interface WithdrawAsset extends Struct {
@@ -87,6 +87,13 @@ export default {
LookupTarget: 'AccountId',
ModuleId: 'LockIdentifier',
MultiAddress: 'GenericMultiAddress',
MultiSigner: {
_enum: {
Ed25519: '[u8; 32]',
Sr25519: '[u8; 32]',
Ecdsa: '[u8; 33]'
}
},
Moment: 'UInt<64, Moment>',
OpaqueCall: 'Bytes',
Origin: 'DoNotConstruct<Origin>',
@@ -174,6 +174,16 @@ export interface Moment extends UInt {}
/** @name MultiAddress */
export interface MultiAddress extends GenericMultiAddress {}
/** @name MultiSigner */
export interface MultiSigner extends Enum {
readonly isEd25519: boolean;
readonly asEd25519: U8aFixed;
readonly isSr25519: boolean;
readonly asSr25519: U8aFixed;
readonly isEcdsa: boolean;
readonly asEcdsa: U8aFixed;
}
/** @name OpaqueCall */
export interface OpaqueCall extends Bytes {}
+4
View File
@@ -49,6 +49,10 @@ export class BitVec extends Raw {
return this.length + compactToU8a(this.bitLength()).length;
}
public toHuman (): string {
return `0b${[...this.toU8a(true)].map((d) => `00000000${d.toString(2)}`.slice(-8)).join('_')}`;
}
/**
* @description Returns the base runtime type name for this instance
*/